mirror of
https://github.com/PikaMug/Quests.git
synced 2024-12-01 23:23:22 +01:00
Do not check perms for non-players entities, fixes #453
This commit is contained in:
parent
063051cda2
commit
502ea53f9a
@ -3787,9 +3787,12 @@ public class Quests extends JavaPlugin implements ConversationAbandonedListener
|
|||||||
* Checks if player CANNOT use Quests
|
* Checks if player CANNOT use Quests
|
||||||
*
|
*
|
||||||
* @param uuid the entity UUID to be checked
|
* @param uuid the entity UUID to be checked
|
||||||
* @return {@code true} if entity has no permission
|
* @return {@code true} if entity has no permission or is not a player
|
||||||
*/
|
*/
|
||||||
public boolean checkQuester(UUID uuid) {
|
public boolean checkQuester(UUID uuid) {
|
||||||
|
if (!(Bukkit.getPlayer(uuid) instanceof Player)) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
Player p = Bukkit.getPlayer(uuid);
|
Player p = Bukkit.getPlayer(uuid);
|
||||||
if (p.isOp()) {
|
if (p.isOp()) {
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user