Fixed phpunit testing
Fixed bug when admin edit profile, perms were reset