use permissions.js in more places for more consistent results