Skip to content

Commit

Permalink
Merge pull request alectrocute#6 from Kbman99/patch-1
Browse files Browse the repository at this point in the history
Fix logger_setup.py issue
  • Loading branch information
MaxHalford authored Dec 1, 2017
2 parents 183c887 + effd6a1 commit 1b6fe56
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions app/logger_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ def add_fields(_, level, event_dict):
return event_dict

# Add a handler to write log messages to a file
if app.config.get('LOG_FILE'):
file_handler = RotatingFileHandler(app.config['LOG_FILENAME'],
app.config['LOG_MAXBYTES'],
app.config['LOG_BACKUPS'],
'a',
if app.config.get('LOG_FILENAME'):
file_handler = RotatingFileHandler(filename=app.config['LOG_FILENAME'],
maxBytes=app.config['LOG_MAXBYTES'],
backupCount=app.config['LOG_BACKUPS'],
mode='a',
encoding='utf-8')
file_handler.setLevel(logging.DEBUG)
app.logger.addHandler(file_handler)
Expand Down

0 comments on commit 1b6fe56

Please sign in to comment.