diff --git a/pkg/models/document.go b/pkg/models/document.go index 8cc4391ee..fd5b9f29c 100644 --- a/pkg/models/document.go +++ b/pkg/models/document.go @@ -667,6 +667,7 @@ func (d *Document) replaceAssocations(db *gorm.DB) error { if err := db. Session(&gorm.Session{SkipHooks: true}). Model(&d). + Unscoped(). Association("Approvers"). Replace(d.Approvers); err != nil { return err