Also handle case of carda and cardb but no main

This commit is contained in:
Kovid Goyal 2017-06-15 12:26:51 +05:30
parent ad5e243821
commit 5bd9418fae
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -411,6 +411,8 @@ class Device(DeviceConfig, DevicePlugin):
drives['carda'] = drives.pop('cardb')
if drives.get('main') is None and drives.get('carda') is not None:
drives['main'] = drives.pop('carda')
if drives.get('carda') is None and drives.get('cardb') is not None:
drives['carda'] = drives.pop('cardb')
if drives.get('main') is None:
raise DeviceError(_('Unable to detect the %s mount point. Try rebooting.')%self.__class__.__name__)
pat = self.OSX_MAIN_MEM_VOL_PAT