Identity has isAuthorized method + code cleanup