File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change 11
11
12
12
def create_db (discord_client , db_name , guild_id ):
13
13
"""
14
- Cross platform way of init-ing a DB
15
- If testing on a Unix local, you may need to use:
16
- db_path = ((Path.cwd() / db_name) if os.name == 'nt' else Path(f'{pathlib.Path.home()}/app/db/{db_name}'))
14
+ Cross-platform way of init-ing a DB
17
15
"""
18
- db_path = ((Path .cwd () / db_name ) if os .name == 'nt' else Path (f'/app/db/{ db_name } ' ))
16
+ db_path = ((Path .cwd () / 'db' / db_name ))
17
+
19
18
log_info (f'Loading Database...{ db_path } ' )
20
19
21
20
if pathlib .Path (db_path ).is_file () is False :
Original file line number Diff line number Diff line change 9
9
from logs .logger import *
10
10
from __main__ import config
11
11
12
- db_path = ((Path .cwd () / config ["Database_name" ])
13
- if os .name == 'nt'
14
- else Path (f'/app/db/{ config ["Database_name" ]} ' ))
12
+
13
+ db_path = ((Path .cwd () / 'db' / config ['Database_name' ]))
15
14
16
15
17
16
def see_top_10 ():
You can’t perform that action at this time.
0 commit comments