mirror of
https://github.com/sasjs/adapter.git
synced 2026-01-18 01:20:05 +00:00
fix(lint): fixed code style
This commit is contained in:
@@ -314,9 +314,7 @@ export class ContextManager {
|
|||||||
contextId: string,
|
contextId: string,
|
||||||
accessToken?: string
|
accessToken?: string
|
||||||
): Promise<ContextAllAttributes> {
|
): Promise<ContextAllAttributes> {
|
||||||
const {
|
const { result: context } = await this.requestClient
|
||||||
result: context
|
|
||||||
} = await this.requestClient
|
|
||||||
.get<ContextAllAttributes>(
|
.get<ContextAllAttributes>(
|
||||||
`${this.serverUrl}/compute/contexts/${contextId}`,
|
`${this.serverUrl}/compute/contexts/${contextId}`,
|
||||||
accessToken
|
accessToken
|
||||||
|
|||||||
@@ -571,9 +571,9 @@ export class SASViyaApiClient {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const {
|
const { result: createFolderResponse } = await this.requestClient.post<
|
||||||
result: createFolderResponse
|
Folder
|
||||||
} = await this.requestClient.post<Folder>(
|
>(
|
||||||
`/folders/folders?parentFolderUri=${parentFolderUri}`,
|
`/folders/folders?parentFolderUri=${parentFolderUri}`,
|
||||||
{
|
{
|
||||||
name: folderName,
|
name: folderName,
|
||||||
@@ -852,9 +852,7 @@ export class SASViyaApiClient {
|
|||||||
throw new Error(`URI of job definition was not found.`)
|
throw new Error(`URI of job definition was not found.`)
|
||||||
}
|
}
|
||||||
|
|
||||||
const {
|
const { result: jobDefinition } = await this.requestClient
|
||||||
result: jobDefinition
|
|
||||||
} = await this.requestClient
|
|
||||||
.get<JobDefinition>(
|
.get<JobDefinition>(
|
||||||
`${this.serverUrl}${jobDefinitionLink.href}`,
|
`${this.serverUrl}${jobDefinitionLink.href}`,
|
||||||
accessToken
|
accessToken
|
||||||
|
|||||||
@@ -91,10 +91,7 @@ export class SessionManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private async createAndWaitForSession(accessToken?: string) {
|
private async createAndWaitForSession(accessToken?: string) {
|
||||||
const {
|
const { result: createdSession, etag } = await this.requestClient
|
||||||
result: createdSession,
|
|
||||||
etag
|
|
||||||
} = await this.requestClient
|
|
||||||
.post<Session>(
|
.post<Session>(
|
||||||
`${this.serverUrl}/compute/contexts/${
|
`${this.serverUrl}/compute/contexts/${
|
||||||
this.currentContext!.id
|
this.currentContext!.id
|
||||||
|
|||||||
@@ -97,9 +97,14 @@ export class RequestClient implements HttpClient {
|
|||||||
})
|
})
|
||||||
.catch(async (e) => {
|
.catch(async (e) => {
|
||||||
return await this.handleError(e, () =>
|
return await this.handleError(e, () =>
|
||||||
this.get<T>(url, accessToken, contentType, overrideHeaders).catch((err) => {
|
this.get<T>(url, accessToken, contentType, overrideHeaders).catch(
|
||||||
throw prefixMessage(err, 'Error while executing handle error callback. ')
|
(err) => {
|
||||||
})
|
throw prefixMessage(
|
||||||
|
err,
|
||||||
|
'Error while executing handle error callback. '
|
||||||
|
)
|
||||||
|
}
|
||||||
|
)
|
||||||
).catch((err) => {
|
).catch((err) => {
|
||||||
throw prefixMessage(err, 'Error while handling error. ')
|
throw prefixMessage(err, 'Error while handling error. ')
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user