Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Unable to use /team setowner #531

Closed
PhuryWasTaken opened this issue Dec 31, 2023 · 1 comment · Fixed by #544
Closed

[BUG] Unable to use /team setowner #531

PhuryWasTaken opened this issue Dec 31, 2023 · 1 comment · Fixed by #544
Assignees
Labels
bug Something isn't working

Comments

@PhuryWasTaken
Copy link

What is the bug?

image
image

I attempted to make one of my team members the owner using /team setowner. When I tried the command, I got an error message in Minecraft chat and my console. It said to report the issue here.

Expected Behaviour

I expected BetterTeams to make the player (Areebz) the owner of my team.

How to Reproduce

Type "/team setowner (Team Member)"

Error message

java.lang.ClassCastException: class org.bukkit.craftbukkit.v1_20_R1.CraftOfflinePlayer cannot be cast to class org.bukkit.command.CommandSender (org.bukkit.craftbukkit.v1_20_R1.CraftOfflinePlayer and org.bukkit.command.CommandSender are in unnamed module of loader java.net.URLClassLoader @5ce65a89)
at BetterTeams.jar//com.booksaw.betterTeams.commands.team.SetOwnerCommand.onCommand(SetOwnerCommand.java:46)
at BetterTeams.jar//com.booksaw.betterTeams.commands.presets.TeamSubCommand.onCommand(TeamSubCommand.java:46)
at BetterTeams.jar//com.booksaw.betterTeams.commands.ParentCommand.onCommand(ParentCommand.java:135)
at BetterTeams.jar//com.booksaw.betterTeams.BooksawCommand.runExecution(BooksawCommand.java:72)
[15:24:43 ERROR]: Something went wrong while executing the command, please report this https://github.com/booksaw/BetterTeams/issues/new/choose
at BetterTeams.jar//com.booksaw.betterTeams.BooksawCommand.lambda$execute$0(BooksawCommand.java:59)
at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftTask.run(CraftTask.java:101)
at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:57)
at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:840)

Output of /teama version

image

Additional Information

  • The player (Areebz) was already promoted to a team admin at the time of using the command.
  • The player (Areebz) was offline at the time of using the command.
  • The player (Areebz) has no set permissions and is not a server operator.
@PhuryWasTaken PhuryWasTaken added the bug Something isn't working label Dec 31, 2023
booksaw added a commit that referenced this issue Jan 27, 2024
Fixes bug with /team setowner
@booksaw
Copy link
Owner

booksaw commented Jan 27, 2024

This bug has been fixed and the patch will be included in the next update. Thank you for reporting.

booksaw added a commit that referenced this issue Jan 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants