From fda4df67ee2b72c437396d29a7cc72dba0a5f1c0 Mon Sep 17 00:00:00 2001 From: 100gle Date: Mon, 3 Jul 2023 21:44:48 +0800 Subject: [PATCH] bugfix: add missing type --- backend/src/module/database/orm/connector.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/src/module/database/orm/connector.py b/backend/src/module/database/orm/connector.py index ef6e972a..d250bbdc 100644 --- a/backend/src/module/database/orm/connector.py +++ b/backend/src/module/database/orm/connector.py @@ -15,7 +15,7 @@ class Connector: self, table_name: str, data: dict, database: PathLike[str] | Path = DATA_PATH ): # Create folder if not exists - if isinstance(database, PathLike): + if isinstance(database, PathLike, str): database = Path(database) database.parent.mkdir(parents=True, exist_ok=True)