🐛 Fix ERROR: column reference "id" is ambiguous (SQLSTATE 42702)
This commit is contained in:
parent
f392f12f76
commit
da62afe2d1
@ -47,7 +47,7 @@ func adminTriggerScanTask(c *fiber.Ctx) error {
|
||||
})
|
||||
database.C.Clauses(clause.OnConflict{
|
||||
Columns: []clause.Column{{Name: "hash"}},
|
||||
DoUpdates: clause.Assignments(map[string]interface{}{}),
|
||||
DoUpdates: clause.AssignmentColumns([]string{"thumbnail", "title", "content", "description", "published_at"}),
|
||||
}).Create(&result)
|
||||
|
||||
log.Info().Str("source", src.ID).Int("count", len(result)).Msg("Scanned a news sources.")
|
||||
|
@ -49,7 +49,7 @@ func ScanNewsSources(eager ...bool) {
|
||||
})
|
||||
database.C.Clauses(clause.OnConflict{
|
||||
Columns: []clause.Column{{Name: "hash"}},
|
||||
DoUpdates: clause.Assignments(map[string]interface{}{}),
|
||||
DoUpdates: clause.AssignmentColumns([]string{"thumbnail", "title", "content", "description", "published_at"}),
|
||||
}).Create(&result)
|
||||
|
||||
log.Info().Str("source", src.ID).Int("count", len(result)).Msg("Scanned a news sources.")
|
||||
|
Loading…
x
Reference in New Issue
Block a user