Skip to content

Commit dd511ec

Browse files
committed
fix(devtools): don't connect devtools on production
1 parent 609dad1 commit dd511ec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ function Model<M extends Models, MT extends ModelType, E>(
139139
Global.withDevTools =
140140
typeof window !== 'undefined' &&
141141
(window as any).__REDUX_DEVTOOLS_EXTENSION__
142-
if (Global.withDevTools) {
142+
if (Global.withDevTools && middlewares.config.devtools.enable) {
143143
Global.devTools = (window as any).__REDUX_DEVTOOLS_EXTENSION__
144144
Global.devTools.connect()
145145
}

0 commit comments

Comments
 (0)