2013-06-20 17:44:06 +08:00
|
|
|
From 46f2ad93239b4f6c92b8187f4e6b54c6d19e9aa3 Mon Sep 17 00:00:00 2001
|
2013-04-03 15:20:29 +08:00
|
|
|
From: Hudson <hudson@mydomain.com>
|
|
|
|
Date: Wed, 3 Apr 2013 02:16:56 -0500
|
2013-04-10 10:36:11 +08:00
|
|
|
Subject: [PATCH] Revert "Throw exception for disabled plugin tasks. Fixes
|
|
|
|
BUKKIT-3951"
|
2013-04-03 15:20:29 +08:00
|
|
|
|
|
|
|
This reverts commit 052e955ed71a30516a5e9cfd76649daaba4ae7d8.
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java b/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
|
2013-05-04 07:24:15 +08:00
|
|
|
index 84dcfcc..0a5c61a 100644
|
2013-04-03 15:20:29 +08:00
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
|
|
|
|
@@ -15,7 +15,6 @@ import java.util.concurrent.atomic.AtomicReference;
|
|
|
|
import java.util.logging.Level;
|
|
|
|
|
|
|
|
import org.apache.commons.lang.Validate;
|
|
|
|
-import org.bukkit.plugin.IllegalPluginAccessException;
|
|
|
|
import org.bukkit.plugin.Plugin;
|
|
|
|
import org.bukkit.scheduler.BukkitScheduler;
|
|
|
|
import org.bukkit.scheduler.BukkitTask;
|
|
|
|
@@ -390,9 +389,6 @@ public class CraftScheduler implements BukkitScheduler {
|
|
|
|
private static void validate(final Plugin plugin, final Object task) {
|
|
|
|
Validate.notNull(plugin, "Plugin cannot be null");
|
|
|
|
Validate.notNull(task, "Task cannot be null");
|
|
|
|
- if (!plugin.isEnabled()) {
|
|
|
|
- throw new IllegalPluginAccessException("Plugin attempted to register task while disabled");
|
|
|
|
- }
|
|
|
|
}
|
|
|
|
|
|
|
|
private int nextId() {
|
|
|
|
--
|
2013-06-02 13:15:15 +08:00
|
|
|
1.8.1.2
|
2013-04-03 15:20:29 +08:00
|
|
|
|