Delete data from backend when uninstalling, fixes #132 (#143)

This commit is contained in:
David Dworken
2023-12-10 09:15:11 -08:00
committed by GitHub
parent 3a49c9c11f
commit 7272ca8448
5 changed files with 50 additions and 3 deletions

View File

@ -21,6 +21,7 @@ type EncHistoryEntry struct {
ReadCount int `json:"read_count"`
}
// TODO: Move this struct to the backend directory
type Device struct {
UserId string `json:"user_id"`
DeviceId string `json:"device_id"`
@ -32,6 +33,8 @@ type Device struct {
RegistrationDate time.Time `json:"registration_date"`
// Test devices, that should be aggressively cleaned from the DB
IsIntegrationTestDevice bool `json:"is_integration_test_device"`
// Whether this device was uninstalled
UninstallDate time.Time `json:"uninstall_date"`
}
// Represents a request to get all history entries from a given device. Used as part of bootstrapping