mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-10 12:08:59 +08:00
Fix multiple exceptions
Turns out that this syntax needs to be surrounded in brackets. Contributes to issue CURA-844.
This commit is contained in:
parent
ccf9796b51
commit
816e94c760
@ -15,7 +15,7 @@ import io #To write config files to strings as if they were files.
|
||||
def importVersion1(serialised):
|
||||
try:
|
||||
return MachineInstance(serialised)
|
||||
except configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError:
|
||||
except (configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError):
|
||||
return None
|
||||
|
||||
## A representation of a machine instance used as intermediary form for
|
||||
|
@ -14,7 +14,7 @@ import io #To write config files to strings as if they were files.
|
||||
def importVersion1(serialised):
|
||||
try:
|
||||
return Profile(serialised)
|
||||
except configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError:
|
||||
except (configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError):
|
||||
return None
|
||||
|
||||
## A representation of a profile used as intermediary form for conversion from
|
||||
|
Loading…
x
Reference in New Issue
Block a user