Skip to content

Handle unsupported versions better

Latest
Compare
Choose a tag to compare
@Rapha149 Rapha149 released this 13 Dec 17:25
· 1 commit to main since this release

This release adds better handling for unsupported versions by initializing the version wrapper not in a static block anymore, but in the method SignGUI#builder and throwing an exception (SignGUIVersionException) when the server version is unsupported.
This has the effect that it's now possible to catch that exception and handle it (e.g. switching to a backup implementation of getting user input like via chat).
Warning: this unfortunately means that you must catch the exception and handle it somehow now, but in my opinion the advantage of being able to catch it outweighs the disadvantage of having to catch it.