File tree Expand file tree Collapse file tree
src/main/java/com/extendedclip/papi/expansion/server Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ public final class ServerUtils {
2424 private boolean hasTpsMethod = false ;
2525
2626 public ServerUtils () {
27- variants .put ("Spigot" , "org.spigotnc .SpigotConfig" );
27+ variants .put ("Spigot" , "org.spigotmc .SpigotConfig" );
2828 variants .put ("Paper" , "com.destroystokyo.paper.PaperConfig" );
2929 variants .put ("Tuinity" , "com.tuinity.tuinity.config.TuinityConfig" );
3030 variants .put ("Airplane" , "gg.airplane.AirplaneConfig" );
@@ -106,9 +106,9 @@ public double[] getTps() {
106106 private void resolveTPSHandler () {
107107 try {
108108 // If this throws is the server not a fork...
109- Bukkit . getTPS ( );
109+ Class . forName ( "org.bukkit. Bukkit" ). getMethod ( "getTPS" );
110110 hasTpsMethod = true ;
111- } catch (Exception ignored ) {
111+ } catch (ClassNotFoundException | NoSuchMethodException ignored ) {
112112 final String mcVersion = Bukkit .getServer ().getClass ().getPackage ().getName ().split ("\\ ." )[3 ];
113113
114114 try {
You can’t perform that action at this time.
0 commit comments