replaced args so Req is always last argument passed to function in cowboy_session