mirror of
https://github.com/pi-hole/pi-hole
synced 2025-01-03 04:30:55 +00:00
Fix Ctrl-C inadvertently deleting domains files
This commit is contained in:
parent
3aa525b0c0
commit
cd7c00ef8e
@ -181,6 +181,7 @@ gravity_Supernova() {
|
|||||||
echo ""
|
echo ""
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
gravity_Blackbody=true
|
||||||
}
|
}
|
||||||
|
|
||||||
# Download specified URL and perform checks on HTTP status and file content
|
# Download specified URL and perform checks on HTTP status and file content
|
||||||
@ -554,8 +555,8 @@ gravity_Cleanup() {
|
|||||||
rm ${piholeDir}/*.tmp 2> /dev/null
|
rm ${piholeDir}/*.tmp 2> /dev/null
|
||||||
rm /tmp/*.phgpb 2> /dev/null
|
rm /tmp/*.phgpb 2> /dev/null
|
||||||
|
|
||||||
# Ensure this function only runs alongside gravity_Supernova()
|
# Ensure this function only runs when gravity_Supernova() has completed
|
||||||
if [[ "${skipDownload}" == false ]]; then
|
if [[ "${gravity_Blackbody:-}" == true ]]; then
|
||||||
# Remove any unused .domains files
|
# Remove any unused .domains files
|
||||||
for file in ${piholeDir}/*.${domainsExtension}; do
|
for file in ${piholeDir}/*.${domainsExtension}; do
|
||||||
# If list is not in active array, then remove it
|
# If list is not in active array, then remove it
|
||||||
|
Loading…
Reference in New Issue
Block a user