Fix flat JSON file

PR #2140 contains a bug when handling flat JSON files. FIRST_FINDING should only be set to true in the case of structured JSON output, since it is only in that case that fileout_insert_warning() appends a comma to the JSON file. This commit fixes the problem.
This commit is contained in:
David Cooper 2022-04-07 13:57:49 -04:00
parent 46b66c777a
commit 09973c8c44

View File

@ -1313,8 +1313,8 @@ fileout_insert_warning() {
else
echo -e ", " >>"$JSONFILE"
fi
FIRST_FINDING=true
fi
FIRST_FINDING=true
}
fileout_csv_finding() {