mirror of
https://github.com/jcreek/CosmicClash.git
synced 2026-09-11 00:14:00 +00:00
feat: make proposal responses durable
This commit is contained in:
@@ -37,6 +37,10 @@ func (p postgresProposalBackend) Get(ctx context.Context, playerID, proposalID s
|
||||
return store.GetProposal(ctx, p.db, playerID, proposalID, now)
|
||||
}
|
||||
|
||||
func (p postgresProposalBackend) Respond(ctx context.Context, playerID, proposalID, idempotencyKey string, accept bool, expectedRevision uint64, now time.Time) (domain.Proposal, error) {
|
||||
return store.RespondToProposal(ctx, p.db, playerID, proposalID, idempotencyKey, accept, expectedRevision, now)
|
||||
}
|
||||
|
||||
func ProposalProviderFromStore(db *sql.DB) ProposalBackend {
|
||||
return postgresProposalBackend{db: db}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user