Skip to content

Commit

Permalink
Prevent ProtocolLib from bricking the plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
aromaa committed Feb 25, 2024
1 parent 26e577f commit 1c13403
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,14 @@ public void onEnable()

if (this.protocolLibHelper != null)
{
this.protocolLibHelper.onEnable();
try
{
this.protocolLibHelper.onEnable();
}
catch (Throwable ignore)
{
this.getServer().getPluginManager().registerEvents(new EntityPotionEffectEventListener(this.worldGuardPlugin, this.sessionManager), this);
}
}
else
{
Expand Down

0 comments on commit 1c13403

Please sign in to comment.