From 46ab44c04fe5e5f3f988fd7dba1485acdeaac222 Mon Sep 17 00:00:00 2001 From: Patrik Segedy Date: Mon, 11 Sep 2023 14:54:28 +0200 Subject: [PATCH] RHINENG-1604: return updated system_platform record --- listener/upload.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/listener/upload.go b/listener/upload.go index 24fec8352..b07b691b2 100644 --- a/listener/upload.go +++ b/listener/upload.go @@ -377,6 +377,9 @@ func storeOrUpdateSysPlatform(tx *gorm.DB, system *models.SystemPlatform, colsTo utils.LogWarn("err", errSelect, "couldn't find system for update") } + // return system_platform record after update + tx = tx.Clauses(clause.Returning{}) + if system.ID != 0 { // update system err = tx.Select(colsToUpdate).Updates(system).Error