1
mirror of https://gitlab.com/commento/commento.git synced 2025-06-29 22:56:37 -04:00

domain_delete.go: delete entries from pages on domain delete

This commit is contained in:
Adhityaa Chandrasekar
2018-10-08 02:34:03 -04:00
parent 6d3f8171e5
commit 0c6ccdc0a1

View File

@ -60,6 +60,16 @@ func domainDelete(domain string) error {
return errorInternal return errorInternal
} }
statement = `
DELETE FROM pages
WHERE pages.domain = $1;
`
_, err = db.Exec(statement, domain)
if err != nil {
logger.Errorf(statement, domain)
return errorInternal
}
return nil return nil
} }