fix(app): Normalize flash type
Changed flash messages to use types provided by Bootstrap Closes #16395
This commit is contained in:
@@ -30,7 +30,7 @@ export default function prodErrorHandler() {
|
||||
if (type === 'html') {
|
||||
if (typeof req.flash === 'function') {
|
||||
req.flash(
|
||||
handled.type || 'errors',
|
||||
handled.type || 'danger',
|
||||
{ msg: message }
|
||||
);
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ export default function flashCheaters() {
|
||||
EXCLUDED_PATHS.indexOf(req.path) === -1 &&
|
||||
req.user && req.url !== '/' && req.user.isCheater
|
||||
) {
|
||||
req.flash('errors', {
|
||||
req.flash('danger', {
|
||||
msg: dedent`
|
||||
Upon review, this account has been flagged for academic
|
||||
dishonesty. If you’re the owner of this account contact
|
||||
|
||||
Reference in New Issue
Block a user