Detected corrupt/missing conf file where possible...

#56 - Should help prevent this going forward...
This commit is contained in:
RandomNinjaAtk 2023-08-12 10:37:43 -04:00 committed by GitHub
parent e2dc7de05a
commit c17868b51d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -52,3 +52,19 @@ verifyApiAccess () {
fi fi
done done
} }
ConfValidationCheck () {
logfileSetup
if [ ! -f "/config/extended.conf" ]; then
log "ERROR :: \"extended.conf\" file is missing..."
log "ERROR :: Download the extended.conf config file and place it into \"/config\" folder..."
log "ERROR :: Exiting..."
exit
fi
if [ -z "$enableAutoConfig" ]; then
log "ERROR :: \"extended.conf\" file is unreadable..."
log "ERROR :: Likely caused by editing with a non unix/linux compatible editor, to fix, replace the file with a valid one or correct the line endings..."
log "ERROR :: Exiting..."
exit
fi
}