Fixes in user permissions patches