mirror of
https://github.com/PaperMC/Paper.git
synced 2024-08-26 14:43:14 +02:00
28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
From ed59e1ea0da9d4136dffe6056056748bcef8bfc3 Mon Sep 17 00:00:00 2001
|
|
From: md_5 <md_5@live.com.au>
|
|
Date: Sat, 2 Feb 2013 16:40:42 +1100
|
|
Subject: [PATCH] Add nag for bad plugins.
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java b/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java
|
|
index 29ec3fc..a31500c 100644
|
|
--- a/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java
|
|
+++ b/src/main/java/org/bukkit/plugin/java/PluginClassLoader.java
|
|
@@ -69,6 +69,13 @@ public class PluginClassLoader extends URLClassLoader {
|
|
if (name.startsWith("org.bukkit.") || name.startsWith("net.minecraft.")) {
|
|
throw new ClassNotFoundException(name);
|
|
}
|
|
+
|
|
+ // Spigot start
|
|
+ if (checkGlobal && name.equals("org.mcstats.Metrics")) {
|
|
+ loader.server.getLogger().warning("Plugin from file: " + getURLs()[0] + " has embedded Metrics in the default package. This is not advisable, go nag them!");
|
|
+ }
|
|
+ // Spigot end
|
|
+
|
|
Class<?> result = classes.get(name);
|
|
|
|
if (result == null) {
|
|
--
|
|
1.8.2.1
|
|
|