Various sender reference improvements. Fixes MassiveCraft/Factions#726.
This commit is contained in:
@ -471,6 +471,20 @@ public class EngineMain extends EngineAbstract
|
||||
|
||||
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = true)
|
||||
public void onChunksChange(EventFactionsChunksChange event)
|
||||
{
|
||||
// For security reasons we block the chunk change on any error since an error might block security checks from happening.
|
||||
try
|
||||
{
|
||||
onChunksChangeInner(event);
|
||||
}
|
||||
catch (Throwable throwable)
|
||||
{
|
||||
event.setCancelled(true);
|
||||
throwable.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
public void onChunksChangeInner(EventFactionsChunksChange event)
|
||||
{
|
||||
// Args
|
||||
final MPlayer msender = event.getMSender();
|
||||
|
Reference in New Issue
Block a user