Skip to content

Commit 05df01d

Browse files
committed
Lint fixes
1 parent d61f528 commit 05df01d

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

src/lib/seam/connect/seam-api-request.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
import type { AxiosRequestConfig } from 'axios'
2+
23
import type { Client } from './client.js'
4+
import { SeamHttpActionAttempts } from './index.js'
35
import type { SeamHttpRequestOptions } from './options.js'
46
import { resolveActionAttempt } from './resolve-action-attempt.js'
5-
import { SeamHttpActionAttempts } from './index.js'
67

78
export interface SeamApiRequestParent {
89
readonly client: Client
@@ -13,7 +14,7 @@ export type ResponseFromSeamApiRequest<T> =
1314
T extends SeamApiRequest<any, infer TResponse, infer TResourceKey>
1415
? TResourceKey extends keyof TResponse
1516
? TResponse[TResourceKey]
16-
: void
17+
: undefined
1718
: never
1819

1920
export class SeamApiRequest<
@@ -58,7 +59,7 @@ export class SeamApiRequest<
5859
this.options.waitForActionAttempt ??
5960
this.parent.defaults.waitForActionAttempt
6061
if (waitForActionAttempt !== false) {
61-
return resolveActionAttempt(
62+
return await resolveActionAttempt(
6263
data,
6364
SeamHttpActionAttempts.fromClient(client, {
6465
...this.parent.defaults,

test/seam/connect/client.test.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ import {
99
SeamHttpMultiWorkspace,
1010
type WorkspacesListResponse,
1111
} from '@seamapi/http/connect'
12+
1213
import {
13-
SeamApiRequest,
1414
type ResponseFromSeamApiRequest,
15+
SeamApiRequest,
1516
} from 'lib/seam/connect/seam-api-request.js'
1617

1718
test('SeamHttp: fromClient returns instance that uses client', async (t) => {
@@ -185,10 +186,10 @@ test('SeamHttp: request methods return a SeamApiRequest object', async (t) => {
185186
// Ensure that the type of the response is correct.
186187
type Expected = ResponseFromSeamApiRequest<typeof deviceRequest>
187188

188-
const valid_device_type: Expected['device_type'] = 'august_lock'
189-
t.truthy(valid_device_type)
189+
const validDeviceType: Expected['device_type'] = 'august_lock'
190+
t.truthy(validDeviceType)
190191

191192
// @ts-expect-error because it's an invalid device type.
192-
const invalid_device_type: Expected['device_type'] = 'invalid_device_type'
193-
t.truthy(invalid_device_type)
193+
const invalidDeviceType: Expected['device_type'] = 'invalid_device_type'
194+
t.truthy(invalidDeviceType)
194195
})

0 commit comments

Comments
 (0)