refac: stale test entries, failing web tests, Postgre backup bug, Hardcoded MySQL table count, Stale Postgre connection in test, own-scope visibility filter, GetAll ignoring its error, JSON tags in use-case types, 31 copies of DESKTOP_QUERY, ProfileView endpoint paths
This commit is contained in:
1 parent
efecdee200
commit
5d6f378fce
87 files changed
+696
-373
No files matched your search
@@ -34,7 +34,11 @@ func (e *EnforceRetentionUseCase) Tick(now time.Time) (retention.Result, error)
|
||||
|
||||
func (e *EnforceRetentionUseCase) deleteStaleUnverifiedUsers(now time.Time) (int, error) {
|
||||
removed := 0
|
||||
for _, candidate := range e.users.GetAll() {
|
||||
users, err := e.users.GetAll()
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
for _, candidate := range users {
|
||||
if !candidate.IsStaleUnverifiedAt(now) {
|
||||
continue
|
||||
}
|
||||
@@ -48,7 +52,11 @@ func (e *EnforceRetentionUseCase) deleteStaleUnverifiedUsers(now time.Time) (int
|
||||
|
||||
func (e *EnforceRetentionUseCase) deleteStaleInvites(now time.Time) (int, error) {
|
||||
removed := 0
|
||||
for _, candidate := range e.invites.GetAll() {
|
||||
invites, err := e.invites.GetAll()
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
for _, candidate := range invites {
|
||||
if !candidate.IsStaleAt(now) {
|
||||
continue
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user