Skip to content

Commit

Permalink
logger: bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ntzyz committed Sep 20, 2018
1 parent 1d61e02 commit c6fb223
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/logger.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ async function logger (req, res, next) {
// Write log to database
await db.prepare();
// We do NOT need to await here.
if (!/^\/(dist|static)/.match(req.url)) {
if (!/^\/(dist|static|api\/media)/.test(req.url)) {
db.conn.collection('logs').insert({
time: new Date(),
ip: req.headers['x-real-ip'] || req.ip || '0.0.0.0',
Expand Down

0 comments on commit c6fb223

Please sign in to comment.