summaryrefslogtreecommitdiff
path: root/internal/executor/channel.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/executor/channel.go')
-rw-r--r--internal/executor/channel.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/internal/executor/channel.go b/internal/executor/channel.go
index 9392c77..55da7b1 100644
--- a/internal/executor/channel.go
+++ b/internal/executor/channel.go
@@ -273,4 +273,17 @@ func (c *storeChannel) ProposeRoleConfig(_ context.Context, config role.RoleConf
return row.Version, err
}
return row.Version, nil
+}
+
+func (c *storeChannel) ReportVerdict(_ context.Context, approved bool, reasoning string) error {
+ payload, _ := json.Marshal(struct {
+ Approved bool `json:"approved"`
+ Reasoning string `json:"reasoning"`
+ }{Approved: approved, Reasoning: reasoning})
+ return c.store.CreateEvent(&event.Event{
+ TaskID: c.taskID,
+ Kind: event.KindVerdictReported,
+ Actor: event.ActorAgent,
+ Payload: payload,
+ })
} \ No newline at end of file