mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 11:56:05 +08:00
Remove elif after returns
This commit is contained in:
parent
00acc3f31a
commit
f8590be6da
@ -11,13 +11,16 @@ def getLinter(file: Path, settings: dict) -> Optional[Linter]:
|
|||||||
""" Returns a Linter depending on the file format """
|
""" Returns a Linter depending on the file format """
|
||||||
if not file.exists():
|
if not file.exists():
|
||||||
return None
|
return None
|
||||||
elif ".inst" in file.suffixes and ".cfg" in file.suffixes:
|
|
||||||
|
if ".inst" in file.suffixes and ".cfg" in file.suffixes:
|
||||||
return Profile(file, settings)
|
return Profile(file, settings)
|
||||||
elif ".def" in file.suffixes and ".json" in file.suffixes:
|
|
||||||
|
if ".def" in file.suffixes and ".json" in file.suffixes:
|
||||||
if file.stem in ("fdmprinter.def", "fdmextruder.def"):
|
if file.stem in ("fdmprinter.def", "fdmextruder.def"):
|
||||||
return None
|
return None
|
||||||
return Definition(file, settings)
|
return Definition(file, settings)
|
||||||
elif file.parent.stem == "meshes":
|
|
||||||
|
if file.parent.stem == "meshes":
|
||||||
return Meshes(file, settings)
|
return Meshes(file, settings)
|
||||||
|
|
||||||
return None
|
return None
|
||||||
|
Loading…
x
Reference in New Issue
Block a user