nbroad HF staff commited on
Commit
6e89539
·
verified ·
1 Parent(s): 26dc390

move outside for loop

Browse files
Files changed (1) hide show
  1. update.py +9 -9
update.py CHANGED
@@ -217,16 +217,16 @@ def update_webhooks():
217
  else:
218
  to_add.append({"name": m.id, "type": "org"})
219
 
220
- new_watched = webhook2update[0].watched + to_add
221
 
222
- print("There are now", len(new_watched), "items in the watched list")
223
 
224
- api.update_webhook(
225
- webhook_id=id2update,
226
- url=webhook_url,
227
- watched=new_watched,
228
- domains=["discussion"],
229
- secret=WEBHOOK_SECRET,
230
- )
231
 
232
 
 
217
  else:
218
  to_add.append({"name": m.id, "type": "org"})
219
 
220
+ new_watched = webhook2update[0].watched + to_add
221
 
222
+ print("There are now", len(new_watched), "items in the watched list")
223
 
224
+ api.update_webhook(
225
+ webhook_id=id2update,
226
+ url=webhook_url,
227
+ watched=new_watched,
228
+ domains=["discussion"],
229
+ secret=WEBHOOK_SECRET,
230
+ )
231
 
232