Minor fixes to the authorization, fixed how code looks