Skip to content

Commit

Permalink
fix(rabbitmq): fix build with new typescript version
Browse files Browse the repository at this point in the history
  • Loading branch information
GauthierD- committed Jun 4, 2024
1 parent 317a112 commit d6ffcb9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/rabbitmq/src/rabbitmq.decorators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ export const createPipesRpcParamDecorator =
): ParameterDecorator =>
(target, key, index) => {
const args =
Reflect.getMetadata(ROUTE_ARGS_METADATA, target.constructor, key) || {};
Reflect.getMetadata(ROUTE_ARGS_METADATA, target.constructor, key || '') ||
{};

const hasParamData = isString(data);
const paramData = hasParamData ? data : undefined;
Expand All @@ -57,7 +58,7 @@ export const createPipesRpcParamDecorator =
ROUTE_ARGS_METADATA,
assignMetadata(args, type, index, paramData, ...paramPipes),
target.constructor,
key
key || ''
);
};

Expand Down

0 comments on commit d6ffcb9

Please sign in to comment.