Archived
1
0
Fork 0

Auto-remove stale products (#30)

Signed-off-by: Julien Riou <julien@riou.xyz>
This commit is contained in:
Julien Riou 2021-05-14 16:08:09 +02:00
commit b6feb2d656
No known key found for this signature in database
GPG key ID: FF42D23B580C89F7
2 changed files with 2 additions and 2 deletions

View file

@ -25,7 +25,7 @@ type Tweet struct {
LastTweetID int64 `gorm:"index"`
Counter int64 `gorm:"not null;default:1"`
ProductURL string `gorm:"index"`
Product Product `gorm:"not null;references:URL"`
Product Product `gorm:"not null;references:URL;constraint:OnDelete:CASCADE"`
}
// TwitterNotifier to manage notifications to Twitter