Skip to content

Commit

Permalink
fix: Switch request-status to snake case (#389)
Browse files Browse the repository at this point in the history
  • Loading branch information
eftychis authored Feb 18, 2020
1 parent cb7a91b commit 235555e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/userlib/js/src/actor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ test('makeActor', async () => {
'Content-Type': 'application/cbor',
},
body: cbor.encode({
request_type: 'request-status',
request_type: 'request_status',
request_id: expectedCallRequestId,
nonce: nonces[1],
sender_pubkey: senderPubKey,
Expand All @@ -145,7 +145,7 @@ test('makeActor', async () => {
'Content-Type': 'application/cbor',
},
body: cbor.encode({
request_type: 'request-status',
request_type: 'request_status',
request_id: expectedCallRequestId,
nonce: nonces[2],
sender_pubkey: senderPubKey,
Expand All @@ -160,7 +160,7 @@ test('makeActor', async () => {
'Content-Type': 'application/cbor',
},
body: cbor.encode({
request_type: 'request-status',
request_type: 'request_status',
request_id: expectedCallRequestId,
nonce: nonces[3],
sender_pubkey: senderPubKey,
Expand Down
6 changes: 3 additions & 3 deletions src/userlib/js/src/http_agent_types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ export const enum QueryResponseStatus {
// The types of values allowed in the `request_type` field for read requests.
export const enum ReadRequestType {
Query = 'query',
RequestStatus = 'request-status',
RequestStatus = 'request_status',
}

// The fields in a "query" read request.
Expand All @@ -98,13 +98,13 @@ export interface QueryRequest extends Record<string, any> {
arg: BinaryBlob;
}

// The fields in a "request-status" read request.
// The fields in a "request_status" read request.
export interface RequestStatusRequest extends Record<string, any> {
request_type: ReadRequestType.RequestStatus;
request_id: RequestId;
}

// An ADT that represents responses to a "request-status" read request.
// An ADT that represents responses to a "request_status" read request.
export type RequestStatusResponse =
| RequestStatusResponsePending
| RequestStatusResponseReplied
Expand Down

0 comments on commit 235555e

Please sign in to comment.