🐛 Fix opener get wrong dest
This commit is contained in:
parent
1955d94414
commit
af8d665418
@ -89,7 +89,8 @@ func OpenAttachmentByRID(rid string, region ...string) (url string, mimetype str
|
||||
if rawDest == nil {
|
||||
if len(result.Boosts) > 0 {
|
||||
randomIdx := rand.IntN(len(result.Boosts))
|
||||
if des, ok := DestinationsByIndex[randomIdx]; ok {
|
||||
boost := result.Boosts[randomIdx]
|
||||
if des, ok := DestinationsByIndex[boost.Destination]; ok {
|
||||
rawDest = des.Raw
|
||||
json.Unmarshal(rawDest, &dest)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user