Skip to content

Commit

Permalink
fix: move compression middleware to top
Browse files Browse the repository at this point in the history
  • Loading branch information
zeim839 committed Feb 10, 2024
1 parent 5fbf4b5 commit 7e2cb85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ cache.register(...callbacks)
cache.start(config.cache_interval)

app.set('view engine', 'ejs')
app.use(compression())
app.use(bodyParser.urlencoded({ extended: true }))
app.use(cookieParser())
app.use(rateLimit(config.limiter))
Expand All @@ -33,7 +34,6 @@ app.use(express.json())
app.use(session({ secret: config.secret }))
app.use(passport.initialize())
app.use(passport.session())
app.use(compression())

app.use('/api', apiRoute)

Expand Down

0 comments on commit 7e2cb85

Please sign in to comment.