[typescript/nestjs] remove unused imports and allow async configuration (#18745)

This commit is contained in:
Simon Hanna
2024-05-23 14:12:26 +02:00
committed by GitHub
parent 235b57e499
commit f49efe02fd
10 changed files with 14 additions and 14 deletions

View File

@@ -2,11 +2,11 @@
/* tslint:disable:no-unused-variable member-ordering */
{{#useAxiosHttpModule}}
import { Inject, Injectable, Optional } from '@nestjs/common';
import { Injectable, Optional } from '@nestjs/common';
import { HttpService } from '@nestjs/axios';
{{/useAxiosHttpModule}}
{{^useAxiosHttpModule}}
import { HttpService, Inject, Injectable, Optional } from '@nestjs/common';
import { HttpService, Injectable, Optional } from '@nestjs/common';
{{/useAxiosHttpModule}}
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';

View File

@@ -4,7 +4,7 @@ export interface ConfigurationParameters {
apiKeys?: {[ key: string ]: string};
username?: string;
password?: string;
accessToken?: string | (() => string);
accessToken?: string | Promise<string> | (() => string | Promise<string>);
basePath?: string;
withCredentials?: boolean;
}
@@ -13,7 +13,7 @@ export class Configuration {
apiKeys?: {[ key: string ]: string};
username?: string;
password?: string;
accessToken?: string | (() => string);
accessToken?: string | Promise<string> | (() => string | Promise<string>);
basePath?: string;
withCredentials?: boolean;

View File

@@ -11,7 +11,7 @@
*/
/* tslint:disable:no-unused-variable member-ordering */
import { HttpService, Inject, Injectable, Optional } from '@nestjs/common';
import { HttpService, Injectable, Optional } from '@nestjs/common';
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';
import { ApiResponse } from '../model/apiResponse';

View File

@@ -11,7 +11,7 @@
*/
/* tslint:disable:no-unused-variable member-ordering */
import { HttpService, Inject, Injectable, Optional } from '@nestjs/common';
import { HttpService, Injectable, Optional } from '@nestjs/common';
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';
import { Order } from '../model/order';

View File

@@ -11,7 +11,7 @@
*/
/* tslint:disable:no-unused-variable member-ordering */
import { HttpService, Inject, Injectable, Optional } from '@nestjs/common';
import { HttpService, Injectable, Optional } from '@nestjs/common';
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';
import { User } from '../model/user';

View File

@@ -4,7 +4,7 @@ export interface ConfigurationParameters {
apiKeys?: {[ key: string ]: string};
username?: string;
password?: string;
accessToken?: string | (() => string);
accessToken?: string | Promise<string> | (() => string | Promise<string>);
basePath?: string;
withCredentials?: boolean;
}
@@ -13,7 +13,7 @@ export class Configuration {
apiKeys?: {[ key: string ]: string};
username?: string;
password?: string;
accessToken?: string | (() => string);
accessToken?: string | Promise<string> | (() => string | Promise<string>);
basePath?: string;
withCredentials?: boolean;

View File

@@ -11,7 +11,7 @@
*/
/* tslint:disable:no-unused-variable member-ordering */
import { Inject, Injectable, Optional } from '@nestjs/common';
import { Injectable, Optional } from '@nestjs/common';
import { HttpService } from '@nestjs/axios';
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';

View File

@@ -11,7 +11,7 @@
*/
/* tslint:disable:no-unused-variable member-ordering */
import { Inject, Injectable, Optional } from '@nestjs/common';
import { Injectable, Optional } from '@nestjs/common';
import { HttpService } from '@nestjs/axios';
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';

View File

@@ -11,7 +11,7 @@
*/
/* tslint:disable:no-unused-variable member-ordering */
import { Inject, Injectable, Optional } from '@nestjs/common';
import { Injectable, Optional } from '@nestjs/common';
import { HttpService } from '@nestjs/axios';
import { AxiosResponse } from 'axios';
import { Observable, from, of, switchMap } from 'rxjs';

View File

@@ -4,7 +4,7 @@ export interface ConfigurationParameters {
apiKeys?: {[ key: string ]: string};
username?: string;
password?: string;
accessToken?: string | (() => string);
accessToken?: string | Promise<string> | (() => string | Promise<string>);
basePath?: string;
withCredentials?: boolean;
}
@@ -13,7 +13,7 @@ export class Configuration {
apiKeys?: {[ key: string ]: string};
username?: string;
password?: string;
accessToken?: string | (() => string);
accessToken?: string | Promise<string> | (() => string | Promise<string>);
basePath?: string;
withCredentials?: boolean;