You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When starting the server it is possible that the accessed service providing plugins (e.g. for Vault's Economy or Permissions) are loader after Guilds.
Expected Behavior
It to enable properly.
Actual Behavior
Fails to enable (and prints database error on subsequent disable):
[15:28:24] [Server thread/INFO]: [Guilds] Enabling Guilds v3.5.5.6
[15:28:24] [Server thread/INFO]: ________
[15:28:24] [Server thread/INFO]: / _____/
[15:28:24] [Server thread/INFO]: / \ ___ Guilds v3.5.5.6
[15:28:24] [Server thread/INFO]: \ \_\ \ Server Version: git-Spigot-f011ca2-3af81c7 (MC: 1.16.4)
[15:28:24] [Server thread/INFO]: \______ /
[15:28:24] [Server thread/INFO]: \/
[15:28:24] [Server thread/WARN]: It looks like you don't have an Economy plugin on your server! Stopping plugin..
[15:28:24] [Server thread/INFO]: [Guilds] Disabling Guilds v3.5.5.6
[15:28:24] [Server thread/INFO]: Shutting down database...
[15:28:24] [Server thread/ERROR]: Error occurred while disabling Guilds v3.5.5.6 (Is it up to date?)
java.lang.NullPointerException: Cannot invoke "me.glaremasters.guilds.database.DatabaseAdapter.close()" because "this.database" is null
at me.glaremasters.guilds.Guilds.onDisable(Guilds.java:114) ~[?:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:265) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at org.bukkit.plugin.java.JavaPluginLoader.disablePlugin(JavaPluginLoader.java:376) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at org.bukkit.plugin.SimplePluginManager.disablePlugin(SimplePluginManager.java:501) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at me.glaremasters.guilds.Guilds.onEnable(Guilds.java:160) ~[?:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:351) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:480) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugin(CraftServer.java:494) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugins(CraftServer.java:408) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at net.minecraft.server.v1_16_R3.MinecraftServer.loadWorld(MinecraftServer.java:435) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at net.minecraft.server.v1_16_R3.DedicatedServer.init(DedicatedServer.java:218) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:808) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$0(MinecraftServer.java:164) ~[spigot.jar:git-Spigot-f011ca2-3af81c7]
at java.lang.Thread.run(Thread.java:832) [?:?]
Possible Fix
Properly hook into the Economy service provider by using the service register and unregister events. (See how ChestShop does it)
Description
When starting the server it is possible that the accessed service providing plugins (e.g. for Vault's Economy or Permissions) are loader after Guilds.
Expected Behavior
It to enable properly.
Actual Behavior
Fails to enable (and prints database error on subsequent disable):
Possible Fix
Properly hook into the Economy service provider by using the service register and unregister events. (See how ChestShop does it)
Steps to Reproduce
Context
Your Environment
The text was updated successfully, but these errors were encountered: