Do not send project closed event when it's a snapshot restore

Ref #602
This commit is contained in:
Julien Duponchelle committed 2016-08-15 13:30:02 +02:00
1 parent 937ffc7b73
commit 431bd789cb
3 files changed
+11 -4

No files matched your search

+2 -1
View File
@@ -77,7 +77,8 @@ class Snapshot:
"""
yield from self._project.delete_on_computes()
yield from self._project.close()
# We don't send close notif to clients because the close / open dance is purely internal
yield from self._project.close(ignore_notification=True)
shutil.rmtree(os.path.join(self._project.path, "project-files"))
with open(self._path, "rb") as f:
project = yield from import_project(self._project.controller, self._project.id, f, location=self._project.path)