Skip to content

Commit

Permalink
delete site from gdrive backups
Browse files Browse the repository at this point in the history
  • Loading branch information
usmannasir committed Jan 4, 2024
1 parent bee6bb1 commit 4aa7ab3
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions websiteFunctions/website.py
Original file line number Diff line number Diff line change
Expand Up @@ -2612,6 +2612,15 @@ def submitWebsiteDeletion(self, userID=None, data=None):
execPath = execPath + " deleteVirtualHostConfigurations --virtualHostName " + websiteName
ProcessUtilities.popenExecutioner(execPath)

### delete site from dgdrive backups

try:

from websiteFunctions.models import GDriveSites
GDriveSites.objects.filter(domain=websiteName).delete()
except:
pass

data_ret = {'status': 1, 'websiteDeleteStatus': 1, 'error_message': "None"}
json_data = json.dumps(data_ret)
return HttpResponse(json_data)
Expand Down

0 comments on commit 4aa7ab3

Please sign in to comment.