feat: add paranoid check
This commit is contained in:
parent
1574cc38bb
commit
20d037b1e8
@ -124,6 +124,7 @@ begin
|
||||
"recaptcha": null
|
||||
}
|
||||
}'
|
||||
|
||||
$app_dir = Join-Path $env:PROGRAMDATA 'filebrowser'
|
||||
if(-not (Test-Path $app_dir -PathType Container))
|
||||
{
|
||||
@ -142,12 +143,14 @@ begin
|
||||
}
|
||||
}
|
||||
|
||||
if(-not (Test-Path $filebrowser_exe -PathType Leaf))
|
||||
{
|
||||
throw "filebrowser.exe is missing"
|
||||
}
|
||||
|
||||
Set-Alias 'filebrowser' $filebrowser_exe
|
||||
$config_path = Join-Path $app_dir 'config.json'
|
||||
# if(-not (Test-Path $config_path -PathType Leaf))
|
||||
# {
|
||||
$config_json > $config_path
|
||||
# }
|
||||
|
||||
$db_path = Join-Path $app_dir "filebrowser.db"
|
||||
if(Test-Path $db_path -PathType Leaf)
|
||||
|
Loading…
x
Reference in New Issue
Block a user