Skip to content

Commit 96228ba

Browse files
author
Victor Herrera
committed
Fixing old lint errors, not related to the ticket but needed for build
1 parent b70552e commit 96228ba

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/sdk/EnvoyPluginSDK.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ export interface EnvoyRequestBody<Meta, Payload> {
2424
*
2525
* @category SDK
2626
*/
27-
export default class EnvoyPluginSDK<Meta = unknown, Payload = unknown> {
27+
export default class EnvoyPluginSDK<Meta extends object = Record<string, any>, Payload = unknown> {
2828
/**
2929
* Body of the request.
3030
* use `meta` or `payload` to access the relevant properties,

src/sdk/EnvoyRequest.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export interface VerifiedRequest extends Request {
3535
*
3636
* @category Base
3737
*/
38-
export interface EnvoyBaseRequest<Meta = EnvoyMeta, Payload = unknown> extends VerifiedRequest {
38+
export interface EnvoyBaseRequest<Meta extends object = EnvoyMeta, Payload = unknown> extends VerifiedRequest {
3939
envoy: EnvoyPluginSDK<Meta, Payload>;
4040
}
4141

src/sdk/filters.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ export function excludedEmployeesFilterMiddleware<Config>(
5151
}
5252
const excludedEmployees = (config[excludeEmployeesKey] as unknown as Array<string>) || [];
5353
if (!Array.isArray(excludedEmployees)) {
54-
return next(new Error(`${excludeEmployeesKey} is not an array.`));
54+
return next(new Error(`${String(excludeEmployeesKey)} is not an array.`));
5555
}
5656
const employeeId = payload.relationships.employee?.data.id;
5757
if (!employeeId || !excludedEmployees.includes(employeeId)) {

0 commit comments

Comments
 (0)