From 56fbf108f8afb511820352219107a74acfa056a0 Mon Sep 17 00:00:00 2001 From: WillyPillow Date: Thu, 16 Jul 2020 00:38:02 +0800 Subject: [PATCH] Use self.dest.storage.import* wrappers instead. --- qubes/api/admin.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qubes/api/admin.py b/qubes/api/admin.py index c6656e7a..2c9c30d8 100644 --- a/qubes/api/admin.py +++ b/qubes/api/admin.py @@ -499,12 +499,12 @@ class QubesAdminAPI(qubes.api.AbstractQubesAPI): size = volume.size # Clear the volume by importing empty data into it - path = yield from volume.import_data(size) + path = yield from self.dest.storage.import_data(self.arg, size) self.dest.fire_event('domain-volume-import-begin', volume=self.arg, size=size) pathlib.Path(path).touch() try: - yield from volume.import_data_end(True) + yield from self.dest.storage.import_data_end(self.arg, True) except: self.dest.fire_event('domain-volume-import-end', volume=self.arg, success=False)