Spaces:
Sleeping
Sleeping
DIVYANSHI SINGH commited on
Commit ·
0f29378
1
Parent(s): 4c1fc4e
Revert database path to fix HF Docker permissions issue
Browse files- database.py +2 -6
database.py
CHANGED
|
@@ -17,12 +17,8 @@ from pathlib import Path
|
|
| 17 |
import pandas as pd
|
| 18 |
from datetime import datetime
|
| 19 |
|
| 20 |
-
# Database file path
|
| 21 |
-
|
| 22 |
-
if DATA_DIR.exists() and DATA_DIR.is_dir():
|
| 23 |
-
DB_PATH = DATA_DIR / "invoices.db"
|
| 24 |
-
else:
|
| 25 |
-
DB_PATH = Path(__file__).parent / "invoices.db"
|
| 26 |
|
| 27 |
|
| 28 |
def init_db():
|
|
|
|
| 17 |
import pandas as pd
|
| 18 |
from datetime import datetime
|
| 19 |
|
| 20 |
+
# Database file path relative to the project folder
|
| 21 |
+
DB_PATH = Path(__file__).parent / "invoices.db"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22 |
|
| 23 |
|
| 24 |
def init_db():
|