fix(InstanceManager): return None for suffix if there is none
Signed-off-by: Dominik Willner <th33xitus@gmail.com>
This commit is contained in:
@@ -191,7 +191,7 @@ class InstanceManager:
|
|||||||
def _get_instance_suffix(self, file_path: str) -> Union[str, None]:
|
def _get_instance_suffix(self, file_path: str) -> Union[str, None]:
|
||||||
full_name = file_path.split("/")[-1].split(".")[0]
|
full_name = file_path.split("/")[-1].split(".")[0]
|
||||||
|
|
||||||
return full_name.split("-")[-1] if "-" in full_name else full_name
|
return full_name.split("-")[-1] if "-" in full_name else None
|
||||||
|
|
||||||
def _sort_instance_list(self, s: Union[int, str, None]):
|
def _sort_instance_list(self, s: Union[int, str, None]):
|
||||||
if s is None:
|
if s is None:
|
||||||
|
|||||||
Reference in New Issue
Block a user