Skip to content

Commit 610bfde

Browse files
fix: log event hooks
todo: only if log level >= debug
1 parent 27ab162 commit 610bfde

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/plugins/debugger/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,15 @@ module.exports.default = {
3535
name: 'attach error handler',
3636
event: 'init',
3737
action: (app, params, { event }) => {
38+
// move logs to temp-prev-folder, then move temp-prev-folder to prev-folder
3839
if (existsSync(EVENTSFOLDER)) {
3940
moveSync(`${EVENTSFOLDER}`, `${TEMPPREVFOLDER}`)
4041
moveSync(`${TEMPPREVFOLDER}`, `${PREVFOLDER}`)
4142
removeSync(`${PREVFOLDER}previous`)
4243
}
4344

4445
app.errorHandler = wrapErrorHandler(app)
45-
if (params.logEvents)
46-
app.hookHandler = wrapHookHandler(app)
46+
app.hookHandler = wrapHookHandler(app)
4747
}
4848
},
4949
{

0 commit comments

Comments
 (0)