Don't override media annotations when scanning/importing

This commit is contained in:
Deluan
2020-01-18 21:45:44 -05:00
parent 938a92eded
commit fe058aa4a1
9 changed files with 18 additions and 11 deletions
+2 -2
View File
@@ -29,7 +29,7 @@ func (r *searchableRepository) DeleteAll() error {
})
}
func (r *searchableRepository) put(o orm.Ormer, id string, textToIndex string, a interface{}) error {
func (r *searchableRepository) put(o orm.Ormer, id string, textToIndex string, a interface{}, fields ...string) error {
c, err := r.newQuery(o).Filter("id", id).Count()
if err != nil {
return err
@@ -40,7 +40,7 @@ func (r *searchableRepository) put(o orm.Ormer, id string, textToIndex string, a
err = nil
}
} else {
_, err = o.Update(a)
_, err = o.Update(a, fields...)
}
if err != nil {
return err