[BUG] Issues with jp being null in placeholders
lukriq opened this issue ยท 2 comments
Describe the bug
Placeholder error in scoreboard
To Reproduce
Steps to reproduce the behavior:
If I join the server, sometimes the scoreboard and tablist are not shown because the plugin picojobs is given an error
Screenshots and Logs
8:46] [Server thread/WARN]: [Scoreboard] Task #92 for Scoreboard v3.4.4 generated an exception
java.lang.NullPointerException: Cannot invoke "com.gmail.picono435.picojobs.api.JobPlayer.hasJob()" because "jp" is null
at com.gmail.picono435.picojobs.hooks.PlaceholderAPIHook.translatePlaceholders(PlaceholderAPIHook.java:82) ~[?:?]
at com.gmail.picono435.picojobs.hooks.expansions.JobPlayerExpansion.onPlaceholderRequest(JobPlayerExpansion.java:106) ~[?:?]
at me.clip.placeholderapi.PlaceholderHook.onRequest(PlaceholderHook.java:31) ~[?:?]
at me.clip.placeholderapi.replacer.CharsReplacer.apply(CharsReplacer.java:160) ~[?:?]
at me.clip.placeholderapi.PlaceholderAPI.setPlaceholders(PlaceholderAPI.java:70) ~[?:?]
at me.clip.placeholderapi.PlaceholderAPI.setPlaceholders(PlaceholderAPI.java:98) ~[?:?]
at de.xite.scoreboard.utils.Placeholders.replace(Placeholders.java:38) ~[?:?]
at de.xite.scoreboard.manager.ScoreboardPlayer.setScore(ScoreboardPlayer.java:161) ~[?:?]
at de.xite.scoreboard.manager.ScoreboardPlayer.setScoreboard(ScoreboardPlayer.java:58) ~[?:?]
at de.xite.scoreboard.listeners.EventListener$1.run(EventListener.java:37) ~[?:?]
at org.bukkit.craftbukkit.v1_17_R1.scheduler.CraftTask.run(CraftTask.java:82) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at org.bukkit.craftbukkit.v1_17_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:415) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:1269) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at net.minecraft.server.dedicated.DedicatedServer.b(DedicatedServer.java:438) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:1217) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at net.minecraft.server.MinecraftServer.x(MinecraftServer.java:1050) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at net.minecraft.server.MinecraftServer.lambda$0(MinecraftServer.java:305) ~[server.jar:3246-Spigot-6c1c1b2-dc764e7]
at java.lang.Thread.run(Thread.java:831) [?:?]
Software Details:
Server Software: [e.g. Spigot]
Server Software Version [e.g. 1.17.1]
Plugin Version [e.g. v58e0ddd-DEV]
Java Version: [e.g. Java JRE 16]
Additional context
Add any other context about the problem here.
An experimental fix for this issue was added in the latest DEV build. The issue will be closed once I have a confirmation from you that this issue has been fixed.