Only build the authorization error message when needed
The error message is only used if permission
is false, so avoid building it when permission
is true.
The error message is only used if permission
is false, so avoid building it when permission
is true.