Skip to content
Ferdous edited this page Jan 25, 2016 · 2 revisions

#Sessions: Decided to use Clearance gem to do the job, because it would take too long for us to implement ourselves.

###Class: Clearance::Configuration

  • config cookie domain = you want to keep the dot at the beginning of .diversitytickets.org, to make sure the cookie is dropped no matter what website people go on. if they go on www.divesitytickets.org or just diversitytickets.org

  • httppnly

Clearance adds routes for you. They're not in our route file though. We have to delete our routes pointing to our sessions controller. (running rake routes in your terminal will list all the defined routes.) Say we want to use our session controller, which will inherit from the clearance controller, which is not visible to us -it is saved in the gem on rails. Problem = routes are all pointing at the clearance controller and not our sessions controller so there's no way to get to our sessions controller. We could however, turn off the route producing thing and take full control ourselves. Decided not to do that though 😎. Instead we deleted all the session stuff we made.

Everything is on this Pull request.

Random: if you've deleted stuff, you have to use git add -A so the deletions get picked up. (git add . doesn't do that.)