Completed authentication logic in the sessions create action.