Selaa lähdekoodia

Merge pull request #942 from Shopify/restrict-client-metadata-more

Restrict client metadata update more
Evan Huus 8 vuotta sitten
vanhempi
commit
c20cf337d1
1 muutettua tiedostoa jossa 3 lisäystä ja 0 poistoa
  1. 3 0
      client.go

+ 3 - 0
client.go

@@ -612,6 +612,9 @@ func (client *client) backgroundMetadataUpdater() {
 				if specificTopics, err := client.Topics(); err != nil {
 					Logger.Println("Client background metadata topic load:", err)
 					break
+				} else if len(specificTopics) == 0 {
+					Logger.Println("Client background metadata update: no specific topics to update")
+					break
 				} else {
 					topics = specificTopics
 				}