mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-11-15 22:37:33 -06:00
fixes + db changes (#204)
* fixes + db changes * make duration more lenient
This commit is contained in:
parent
446dbb7a72
commit
e681aac589
16 changed files with 401 additions and 78 deletions
|
|
@ -108,7 +108,7 @@ func (p *processor) initiateDomainBlockSideEffects(ctx context.Context, account
|
|||
instance.ContactAccountUsername = ""
|
||||
instance.ContactAccountID = ""
|
||||
instance.Version = ""
|
||||
if err := p.db.UpdateByID(ctx, instance.ID, instance); err != nil {
|
||||
if err := p.db.UpdateByPrimaryKey(ctx, instance); err != nil {
|
||||
l.Errorf("domainBlockProcessSideEffects: db error updating instance: %s", err)
|
||||
}
|
||||
l.Debug("domainBlockProcessSideEffects: instance entry updated")
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ func (p *processor) DomainBlockDelete(ctx context.Context, account *gtsmodel.Acc
|
|||
}, i); err == nil {
|
||||
i.SuspendedAt = time.Time{}
|
||||
i.DomainBlockID = ""
|
||||
if err := p.db.UpdateByID(ctx, i.ID, i); err != nil {
|
||||
if err := p.db.UpdateByPrimaryKey(ctx, i); err != nil {
|
||||
return nil, gtserror.NewErrorInternalError(fmt.Errorf("couldn't update database entry for instance %s: %s", domainBlock.Domain, err))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue