chore: don't prepend FAWE prefix to WorldGuard messages#3111
chore: don't prepend FAWE prefix to WorldGuard messages#3111PierreSchwang wants to merge 1 commit intomainfrom
Conversation
|
Is it potentially better to search for it only being WE/FAWE ? This could be a problem on some addon plugins, but I can't see it being an issue if we ensure users know what plugin their brush/etc is from |
|
Yeah, sounds more reasonable. Can just dropWhile com.sk89q.we / com.fawe and check if the next / first frame is Bukkit I guess |
|
Please take a moment and address the merge conflicts of your pull request. Thanks! |
|
Quick thought, is it worth adding an overload to skip having to stack walk when we know messages are from FAWE (somehow?) |
|
Could be possible - would have to look further into it. iirc, I also tried to implement the more generic approach (like, don't just handle WG but also other third party plugins) - but there has been some reason why that did not work (don't remember what it was exactly tbf, could've been the builtin stuff like message boxes). But WG alone would be fine as well ig |
Overview
Fixes #3110
Description
Checks if the caller is WorldGuard, and don't prepend the
(FAWE)prefix to the message. Requires hidden frames for stuff like https://github.com/EngineHub/WorldGuard/blob/version/7.0.x/worldguard-core/src/main/java/com/sk89q/worldguard/commands/region/RegionCommands.java#L496