mirror of
https://github.com/PlaceholderAPI/PlaceholderAPI.git
synced 2024-12-26 19:08:06 +01:00
Call ExpansionUnregisterEvent when an expansion is unregistered
This commit is contained in:
parent
3b136b7aa2
commit
bec4782b40
@ -20,6 +20,7 @@
|
||||
*/
|
||||
package me.clip.placeholderapi;
|
||||
|
||||
import me.clip.placeholderapi.events.ExpansionUnregisterEvent;
|
||||
import me.clip.placeholderapi.events.PlaceholderHookUnloadEvent;
|
||||
import me.clip.placeholderapi.expansion.PlaceholderExpansion;
|
||||
import me.clip.placeholderapi.expansion.Relational;
|
||||
@ -273,7 +274,7 @@ public class PlaceholderAPI {
|
||||
if (value instanceof PlaceholderExpansion) {
|
||||
PlaceholderExpansion ex = (PlaceholderExpansion) value;
|
||||
if (!ex.persist()) {
|
||||
Bukkit.getPluginManager().callEvent(new PlaceholderHookUnloadEvent(key, value));
|
||||
Bukkit.getPluginManager().callEvent(new ExpansionUnregisterEvent(ex));
|
||||
unregisterPlaceholderHook(key);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user