diff options
| author | Dmitry Zhavoronkov <rudomitori@gmail.com> | 2024-09-02 13:02:15 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-09-02 13:02:15 +0300 |
| commit | 4494ffabb6e17dc760e3be2c2e357e2fa0c2eaa6 (patch) | |
| tree | 513e898b21080733cecd9910dfaab5fc7b6cb4e1 /sub | |
| parent | 2dc59a601cdd8167a597a23ac60bc3ffd793c59d (diff) | |
fix TypeError: this.shortIds.split is not a function (#2507)
* fix TypeError: this.shortIds.split is not a function
Diffstat (limited to 'sub')
| -rw-r--r-- | sub/subJsonService.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sub/subJsonService.go b/sub/subJsonService.go index cbda594a..d1b5baaa 100644 --- a/sub/subJsonService.go +++ b/sub/subJsonService.go @@ -268,13 +268,13 @@ func (s *SubJsonService) realityData(rData map[string]interface{}) map[string]in rltyData["spiderX"] = "/" + random.Seq(15) shortIds, ok := rData["shortIds"].([]interface{}) if ok && len(shortIds) > 0 { - rltyData["shortId"] = shortIds[random.Num(len(shortIds))].(string) + rltyData["shortId"] = shortIds } else { rltyData["shortId"] = "" } serverNames, ok := rData["serverNames"].([]interface{}) if ok && len(serverNames) > 0 { - rltyData["serverName"] = serverNames[random.Num(len(serverNames))].(string) + rltyData["serverName"] = serverNames } else { rltyData["serverName"] = "" } |
