Merge pull request #1507 from QuantumNous/multi-key-manage

feat: implement channel-specific locking for thread-safe polling
This commit is contained in:
Calcium-Ion authored and GitHub committed 2025-08-05 20:40:26 +08:00
commit 2286ec0641
2 files changed
+7 -3

No files matched your search

+4
View File
@@ -1107,6 +1107,10 @@ func ManageMultiKeys(c *gin.Context) {
return
}
lock := model.GetChannelPollingLock(channel.Id)
lock.Lock()
defer lock.Unlock()
switch request.Action {
case "get_key_status":
keys := channel.GetKeys()