Update the roles array index to not overwrite the anonymous string.
Ensure write permissions are returned before read only permissions when authorizing users.