Fix bukkit permission subscriptions

This commit is contained in:
Luck committed 2017-01-14 23:19:11 +00:00
1 parent cd4a684613
commit 6501e5cf8d
7 files changed
+127 -31

No files matched your search

@@ -394,4 +394,13 @@ public interface LuckPermsPlugin {
}
/**
* Called when a users data is refreshed
*
* @param user the user
*/
default void onUserRefresh(User user) {
}
}
@@ -117,6 +117,7 @@ public class User extends PermissionHolder implements Identifiable<UserIdentifie
userData = new UserCache(this, getPlugin().getCalculatorFactory());
userData.preCalculate(getPlugin().getPreProcessContexts(op));
getPlugin().onUserRefresh(this);
}
/**
@@ -139,6 +140,7 @@ public class User extends PermissionHolder implements Identifiable<UserIdentifie
ud.recalculatePermissions();
ud.recalculateMeta();
getPlugin().getApiProvider().fireEventAsync(new UserPermissionRefreshEvent(new UserLink(this)));
getPlugin().onUserRefresh(this);
}
/**