Update statemanagement-quickstart.md

First time reading the Dapr docs, so I might be wrong, but this code sample didn't seem right to me.

Signed-off-by: Hilton Giesenow <hilton@giesenow.com>
This commit is contained in:
Hilton Giesenow 2023-05-11 21:12:37 +03:00 committed by GitHub
parent 66c974278f
commit 3831dad93b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -180,12 +180,12 @@ The `order-processor` service writes, reads, and deletes an `orderId` key/value
const client = new DaprClient()
// Save state into a state store
await client.state.save(DAPR_STATE_STORE_NAME, state)
await client.state.save(DAPR_STATE_STORE_NAME, order)
console.log("Saving Order: ", order)
// Get state from a state store
const savedOrder = await client.state.get(DAPR_STATE_STORE_NAME, order.orderId)
console.log("Getting Order: ", savedOrd)
console.log("Getting Order: ", savedOrder)
// Delete state from the state store
await client.state.delete(DAPR_STATE_STORE_NAME, order.orderId)