diff --git a/go/enclave/storage/enclavedb/events.go b/go/enclave/storage/enclavedb/events.go index ba00c39ee2..f5a505bbc8 100644 --- a/go/enclave/storage/enclavedb/events.go +++ b/go/enclave/storage/enclavedb/events.go @@ -67,8 +67,8 @@ func WriteEventTopic(ctx context.Context, dbTX *sql.Tx, topic *gethcommon.Hash, return uint64(id), nil } -func UpdateEventTopicLifecycle(ctx context.Context, dbTx *sql.Tx, etId uint64, isLifecycle bool) error { - _, err := dbTx.ExecContext(ctx, "update event_topic set lifecycle_event=? where id=?", isLifecycle, etId) +func UpdateEventTypeLifecycle(ctx context.Context, dbTx *sql.Tx, etId uint64, isLifecycle bool) error { + _, err := dbTx.ExecContext(ctx, "update event_type set lifecycle_event=? where id=?", isLifecycle, etId) return err } diff --git a/go/enclave/storage/events_storage.go b/go/enclave/storage/events_storage.go index 20370589ff..84e7859901 100644 --- a/go/enclave/storage/events_storage.go +++ b/go/enclave/storage/events_storage.go @@ -95,7 +95,7 @@ func (es *eventsStorage) handleEventType(ctx context.Context, dbTX *sql.Tx, l *t if err == nil { // in case we determined the current emitted event is not lifecycle, we must update the EventType if !isLifecycle && et.isLifecycle { - err := enclavedb.UpdateEventTopicLifecycle(ctx, dbTX, et.id, isLifecycle) + err := enclavedb.UpdateEventTypeLifecycle(ctx, dbTX, et.id, isLifecycle) if err != nil { return 0, fmt.Errorf("could not update the event type. cause: %w", err) }