gbdev / homebrewhub

A digital repository of of homebrews, patches, hackroms for old consoles. Provides community submission, tagging and rating features.
https://hh.gbdev.io
GNU General Public License v3.0
44 stars 9 forks source link

Req.flashing specific type and message string for login errors #8

Closed avivace closed 2 years ago

avivace commented 6 years ago

Tinkering with passport methods and the authentication strategy, it should be possible to specify more than the bare message in routes, so we can render it differently (e.g. Info or Error), as we are already doing in some of the existing routes:

req.flash('loginMessage', 'Your comment has been saved!')
req.flash('type', 2)