Skip to content

Commit

Permalink
chore(deps-dev): apply updates
Browse files Browse the repository at this point in the history
Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
  • Loading branch information
jerome-benoit committed Jul 29, 2024
1 parent c398be4 commit 01841aa
Show file tree
Hide file tree
Showing 16 changed files with 141 additions and 124 deletions.
244 changes: 122 additions & 122 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -571,6 +571,7 @@ export class OCPP16IncomingRequestService extends OCPPIncomingRequestService {
this.validatePayload = this.validatePayload.bind(this)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public async incomingRequestHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
messageId: string,
Expand Down
2 changes: 2 additions & 0 deletions src/charging-station/ocpp/1.6/OCPP16RequestService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ export class OCPP16RequestService extends OCPPRequestService {
this.buildRequestPayload = this.buildRequestPayload.bind(this)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public async requestHandler<RequestType extends JsonType, ResponseType extends JsonType>(
chargingStation: ChargingStation,
commandName: OCPP16RequestCommand,
Expand Down Expand Up @@ -179,6 +180,7 @@ export class OCPP16RequestService extends OCPPRequestService {
)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
private buildRequestPayload<Request extends JsonType>(
chargingStation: ChargingStation,
commandName: OCPP16RequestCommand,
Expand Down
1 change: 1 addition & 0 deletions src/charging-station/ocpp/1.6/OCPP16ResponseService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -378,6 +378,7 @@ export class OCPP16ResponseService extends OCPPResponseService {
this.validatePayload = this.validatePayload.bind(this)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public async responseHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
commandName: OCPP16RequestCommand,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ export class OCPP20IncomingRequestService extends OCPPIncomingRequestService {
this.validatePayload = this.validatePayload.bind(this)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public async incomingRequestHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
messageId: string,
Expand Down
2 changes: 2 additions & 0 deletions src/charging-station/ocpp/2.0/OCPP20RequestService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ export class OCPP20RequestService extends OCPPRequestService {
this.buildRequestPayload = this.buildRequestPayload.bind(this)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public async requestHandler<RequestType extends JsonType, ResponseType extends JsonType>(
chargingStation: ChargingStation,
commandName: OCPP20RequestCommand,
Expand All @@ -92,6 +93,7 @@ export class OCPP20RequestService extends OCPPRequestService {
)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
private buildRequestPayload<Request extends JsonType>(
chargingStation: ChargingStation,
commandName: OCPP20RequestCommand,
Expand Down
1 change: 1 addition & 0 deletions src/charging-station/ocpp/2.0/OCPP20ResponseService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ export class OCPP20ResponseService extends OCPPResponseService {
this.validatePayload = this.validatePayload.bind(this)
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public async responseHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
commandName: OCPP20RequestCommand,
Expand Down
3 changes: 2 additions & 1 deletion src/charging-station/ocpp/OCPPIncomingRequestService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ export abstract class OCPPIncomingRequestService extends EventEmitter {
return OCPPIncomingRequestService.instance as T
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
protected validateIncomingRequestPayload<T extends JsonType>(
chargingStation: ChargingStation,
commandName: IncomingRequestCommand,
Expand Down Expand Up @@ -81,7 +82,7 @@ export abstract class OCPPIncomingRequestService extends EventEmitter {
return OCPPConstants.OCPP_RESPONSE_REJECTED
}

// eslint-disable-next-line @typescript-eslint/no-unused-vars
// eslint-disable-next-line @typescript-eslint/no-unused-vars, @typescript-eslint/no-unnecessary-type-parameters
public abstract incomingRequestHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
messageId: string,
Expand Down
1 change: 1 addition & 0 deletions src/charging-station/ocpp/OCPPRequestService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -502,6 +502,7 @@ export abstract class OCPPRequestService {
])
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public abstract requestHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
commandName: RequestCommand,
Expand Down
2 changes: 2 additions & 0 deletions src/charging-station/ocpp/OCPPResponseService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ export abstract class OCPPResponseService {
return OCPPResponseService.instance as T
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
protected validateResponsePayload<T extends JsonType>(
chargingStation: ChargingStation,
commandName: RequestCommand,
Expand All @@ -78,6 +79,7 @@ export abstract class OCPPResponseService {

protected emptyResponseHandler = Constants.EMPTY_FUNCTION

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public abstract responseHandler<ReqType extends JsonType, ResType extends JsonType>(
chargingStation: ChargingStation,
commandName: RequestCommand,
Expand Down
1 change: 1 addition & 0 deletions src/charging-station/ocpp/OCPPServiceUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,7 @@ export const ajvErrorsToErrorType = (errors: ErrorObject[] | undefined | null):
return ErrorType.FORMAT_VIOLATION
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
export const convertDateToISOString = <T extends JsonType>(object: T): void => {
for (const key in object) {
// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion, @typescript-eslint/no-non-null-assertion
Expand Down
1 change: 1 addition & 0 deletions src/utils/Configuration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ export class Configuration {
// This is intentional
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
public static getConfigurationSection<T extends ConfigurationSectionType>(
sectionName: ConfigurationSection
): T {
Expand Down
1 change: 1 addition & 0 deletions src/utils/FileUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { handleFileException } from './ErrorUtils.js'
import { logger } from './Logger.js'
import { isNotEmptyString } from './Utils.js'

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
export const watchJsonFile = <T extends JsonType>(
file: string,
fileType: FileType,
Expand Down
1 change: 1 addition & 0 deletions src/utils/Utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,7 @@ export const secureRandom = (): number => {
}

export const JSONStringify = <
// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
T extends
| JsonType
| Record<string, unknown>[]
Expand Down
2 changes: 1 addition & 1 deletion ui/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"prettier": "^3.3.3",
"rimraf": "^6.0.1",
"typescript": "~5.5.4",
"typescript-eslint": "^7.17.0",
"typescript-eslint": "^7.18.0",
"vite": "^5.3.5",
"vitest": "^2.0.4"
}
Expand Down
1 change: 1 addition & 0 deletions ui/web/src/composables/Utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export const getFromLocalStorage = <T>(key: string, defaultValue: T): T => {
return item != null ? (JSON.parse(item) as T) : defaultValue
}

// eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
export const setToLocalStorage = <T>(key: string, value: T): void => {
localStorage.setItem(key, JSON.stringify(value))
}
Expand Down

0 comments on commit 01841aa

Please sign in to comment.