forked from 2009Scape/Server
bugfix for ScriptApi
This commit is contained in:
parent
77960191ba
commit
8dd806214c
1 changed files with 1 additions and 1 deletions
|
|
@ -71,7 +71,7 @@ class ScriptAPI(private val bot: Player) {
|
|||
is Item -> InteractionListener.ITEM
|
||||
else -> -1
|
||||
}
|
||||
val opt: Option? = node.interaction.options.filter { it.name.equals(option, true) }.firstOrNull()
|
||||
val opt: Option? = node.interaction.options.filter {it != null && it.name.equals(option, true) }.firstOrNull()
|
||||
|
||||
if(opt == null){
|
||||
SystemLogger.logWarn("Invalid option name provided: $option")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue