fix permissions fixing, hopefully for good