#24 optimization attempt to implement authorization.