Skip to content

Commit 0e9cbee

Browse files
committed
Fix noLogger ordering
1 parent 08f504b commit 0e9cbee

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,11 @@ function createLogger(options = {}) {
6969
return emptyLogger();
7070
}
7171

72-
// Return if 'console' object is not defined
73-
if (noLogger(options)) return emptyLogger();
74-
7572
const loggerOptions = Object.assign({}, defaults, options):
7673

74+
// Return if 'console' object is not defined
75+
if (noLogger(loggerOptions)) return emptyLogger();
76+
7777
return ({ getState }) => next => (action) => {
7878
// Exit early if predicate function returns 'false'
7979
if (shouldNotLog(getState, action)) return next(action);

0 commit comments

Comments
 (0)