Wednesday, 20 June 2018

Can't seem to get sessions to work

Help my sessions are working as intended by there's a key thing I might be missing so they seem broken and I can't really figure out why.I have in my Routes/user this:https://ift.tt/2Kb287q is supposed to add some formatted errors which I intend to use in the pages where an error might happen. Then, in my app I have the following middlewarehttps://github.com/inabahare/lewd2/blob/Validation/src/app.js#L69Now if I output the errorArray I'll get just what I expect. But when I output req.session in the middleware in app.js I get what I expect from multer, but then I also get err as an empty array.What I wanna do is show errors when errors are happening. So for instance, when an admin adds a user, but they write a too short username I'd like to show it at the form (which would be here)

Submitted June 20, 2018 at 03:23PM by inabahare

No comments:

Post a Comment