kopia lustrzana https://github.com/dgtlmoon/changedetection.io
Sometimes it seems .update wasnt thread safe and isnt used here, just add a clean new dict member
rodzic
5669ae70cc
commit
711853a149
|
@ -130,8 +130,9 @@ class ChangeDetectionStore:
|
||||||
|
|
||||||
def add_watch(self, url, tag):
|
def add_watch(self, url, tag):
|
||||||
|
|
||||||
# @todo deal with exception
|
print("Adding", url, tag)
|
||||||
validators.url(url)
|
# # @todo deal with exception
|
||||||
|
# validators.url(url)
|
||||||
|
|
||||||
# @todo use a common generic version of this
|
# @todo use a common generic version of this
|
||||||
new_uuid = str(uuid_builder.uuid4())
|
new_uuid = str(uuid_builder.uuid4())
|
||||||
|
@ -142,7 +143,7 @@ class ChangeDetectionStore:
|
||||||
'uuid': new_uuid
|
'uuid': new_uuid
|
||||||
})
|
})
|
||||||
|
|
||||||
self.data['watching'].update({_blank['uuid']: _blank})
|
self.data['watching'][new_uuid] = _blank
|
||||||
return new_uuid
|
return new_uuid
|
||||||
|
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue