mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-02 05:44:03 +02:00
update
This commit is contained in:
@@ -9,7 +9,7 @@ if [ -f ${JSONTOCHECK} ]; then
|
|||||||
echo "Checking settings.json format"
|
echo "Checking settings.json format"
|
||||||
|
|
||||||
# Get the default keys from the original file
|
# Get the default keys from the original file
|
||||||
mapfile -t arr < <(jq -r 'keys[]' ${JSONSOURCE})
|
mapfile -t arr < <(jq -r 'keys[]' ${JSONSOURCE}) || (echo "structure is abnormal, restarting database from scratch" && cp ${JSONSOURCE} ${JSONTOCHECK})
|
||||||
|
|
||||||
# Check if all keys are still there, or add them
|
# Check if all keys are still there, or add them
|
||||||
for KEYS in ${arr[@]}; do
|
for KEYS in ${arr[@]}; do
|
||||||
|
|||||||
Reference in New Issue
Block a user