mirror of
https://github.com/hanzo-fi/payments.git
synced 2026-10-30 20:31:20 +00:00
19 lines
503 B
Go
19 lines
503 B
Go
package activities
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/formancehq/payments/internal/models"
|
|
"go.temporal.io/sdk/workflow"
|
|
)
|
|
|
|
func (a Activities) EventsSendAccount(ctx context.Context, account models.Account) error {
|
|
return a.events.Publish(ctx, a.events.NewEventSavedAccounts(account))
|
|
}
|
|
|
|
var EventsSendAccountActivity = Activities{}.EventsSendAccount
|
|
|
|
func EventsSendAccount(ctx workflow.Context, account models.Account) error {
|
|
return executeActivity(ctx, EventsSendAccountActivity, nil, account)
|
|
}
|