Skip to content

Commit fc91c30

Browse files
committed
✨(coreLib:Commands) 使用LinkedHashMap维持命令顺序
1 parent e0ffa91 commit fc91c30

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

scripts/coreLibrary/lib/CommandApi.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ open class Commands : CommandHandler, TabCompleter, CommandHandlerOld {
232232
}
233233
}
234234

235-
protected val nameMap = mutableMapOf<String, CommandInfo>()
235+
protected val nameMap = LinkedHashMap<String, CommandInfo>()
236236
open fun subCommands(): Map<String, CommandInfo> = nameMap
237237
fun getSub(name: String): CommandInfo? = subCommands()[name.lowercase()]
238238

0 commit comments

Comments
 (0)