Skip to content

Commit

Permalink
fix: 修复自定义口令重复的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
hanxi committed Jul 28, 2024
1 parent 36d72d1 commit f788c0f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion xiaomusic/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,11 @@ def append_keyword(self, keys, action):
def append_user_keyword(self):
for k, v in self.user_key_word_dict.items():
self.key_word_dict[k] = v
self.key_match_order.append(k)
if k not in self.key_match_order:
self.key_match_order.append(k)

def init_keyword(self):
self.key_match_order = default_key_match_order()
self.append_keyword(self.keywords_playlocal, "playlocal")
self.append_keyword(self.keywords_play, "play")
self.append_keyword(self.keywords_stop, "stop")
Expand Down

0 comments on commit f788c0f

Please sign in to comment.