If either the editor or administrator role is missing an error will be thrown since those roles are hard-coded. A patch is coming soon that will bypass setting permissions if the roles don't exist.

Files: 
CommentFileSizeAuthor
#1 1942588-d7-1.patch7.06 KBredndahead

Comments

Status:Active» Needs review
StatusFileSize
new7.06 KB

Here is the patch. It also cleans up some whitespace. I also noticed that the multiple calls to user_role_grant_permissions was unnecessary. It can just take an array of permissions. I think this can be done in another issue.

Status:Needs review» Fixed

Looks great. Reviewed and committed to -dev.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.