nifty authentication: session variable getting deleted/unset unexpectedly
evalentini opened this issue · 0 comments
I am having trouble with the session variable set through nifty authentication sessions controller. For some reason, whenever I call one particular action in one of my controllers, the session variable gets unset. Is this a problem with nifty authentication or with my code?
You can see there error in production by doing the following:
1.) go to url -> http://afternoon-coast-4489.herokuapp.com/
2.) click login (upper left corner of page) and login with username => example, password => dummy
3.) you will be redirected to the url and should see a flash message "logged in successfully"
4.) click the save rates button (on left hand side of page immediately below gray banner)
5.) You should see a flash message appear at the top of the page saying that you must login before you can save rates (which of course doesn't make sense since you just logged in)
You can see the source code that is causing the error on the project github repo.
Github repo url => https://github.com/evalentini/mortgage_calculator
Note that the problem is with either the save action of the rates controller or the set method in the rates model. I'm almost positive its in the save action of rates controller though.