mirror of
https://github.com/PikaMug/Quests.git
synced 2024-11-21 18:15:32 +01:00
Only replace Action player if online, fixes #2269
This commit is contained in:
parent
d1ecedebca
commit
fcc1b80771
@ -359,9 +359,15 @@ public class BukkitAction implements Action {
|
||||
}
|
||||
}
|
||||
if (!commands.isEmpty()) {
|
||||
for (final String s : commands) {
|
||||
plugin.getServer().dispatchCommand(plugin.getServer().getConsoleSender(),
|
||||
s.replace("<player>", quester.getPlayer().getName()));
|
||||
for (String s : commands) {
|
||||
if (s.contains("<player>")) {
|
||||
if (player.isOnline()) {
|
||||
s = s.replace("<player>", player.getName());
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
plugin.getServer().dispatchCommand(plugin.getServer().getConsoleSender(), s);
|
||||
}
|
||||
}
|
||||
if (!potionEffects.isEmpty()) {
|
||||
|
Loading…
Reference in New Issue
Block a user