From b372f808ddf1ff0fed03b1f314c0a85e487766cd Mon Sep 17 00:00:00 2001 From: DL6ER Date: Wed, 1 May 2019 17:06:14 +0200 Subject: [PATCH] Fix lint errors Signed-off-by: DL6ER --- advanced/Scripts/query.sh | 2 +- gravity.sh | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/advanced/Scripts/query.sh b/advanced/Scripts/query.sh index 8eb7c404..a4ac895b 100755 --- a/advanced/Scripts/query.sh +++ b/advanced/Scripts/query.sh @@ -180,7 +180,7 @@ if [[ -z "${exact}" ]]; then fi # Get adlist file content as array -if [[ -n "${blockpage}" ]]; then +if [[ -n "${adlist}" ]] || [[ -n "${blockpage}" ]]; then # Retrieve source URLs from gravity database mapfile -t adlists <<< "$(sqlite3 "${gravityDBfile}" "SELECT address FROM vw_adlists;" 2> /dev/null)" fi diff --git a/gravity.sh b/gravity.sh index 331b632d..9f4065e7 100755 --- a/gravity.sh +++ b/gravity.sh @@ -87,10 +87,11 @@ generate_gravity_database() { # Import domains from file and store them in the specified database table database_table_from_file() { # Define locals - local table="${1}" - local source="${2}" - local backup_path="${piholeDir}/migration_backup" - local backup_file="${backup_path}/$(basename "${2}")" + local table source backup_path backup_file + table="${1}" + source="${2}" + backup_path="${piholeDir}/migration_backup" + backup_file="${backup_path}/$(basename "${2}")" # Create database file if not present if [ ! -e "${gravityDBfile}" ]; then