use self.eject

Signed-off-by: gorgobacka <tho.b.j@gmx.de>
This commit is contained in:
gorgobacka
2019-03-27 22:34:48 +01:00
committed by JoeLametta
parent 135cc9ce05
commit eff5fee3f4

View File

@@ -186,7 +186,8 @@ class _CD(BaseCommand):
self.doCommand()
if self.options.eject in ('success', 'always'):
if (self.options.eject == 'success' and self.eject or
self.options.eject == 'always'):
utils.eject_device(self.device)
return None