mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-13 01:37:51 -06: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
2 changed files with 2 additions and 2 deletions
|
@ -15,7 +15,7 @@ import io #To write config files to strings as if they were files.
|
||||||
def importVersion1(serialised):
|
def importVersion1(serialised):
|
||||||
try:
|
try:
|
||||||
return MachineInstance(serialised)
|
return MachineInstance(serialised)
|
||||||
except configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError:
|
except (configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
## A representation of a machine instance used as intermediary form for
|
## 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):
|
def importVersion1(serialised):
|
||||||
try:
|
try:
|
||||||
return Profile(serialised)
|
return Profile(serialised)
|
||||||
except configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError:
|
except (configparser.Error, SettingsError.InvalidFormatError, SettingsError.InvalidVersionError):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
## A representation of a profile used as intermediary form for conversion from
|
## A representation of a profile used as intermediary form for conversion from
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue