revert back to permission, but with cleaner code.