Skip to content

Commit

Permalink
reduce diff
Browse files Browse the repository at this point in the history
  • Loading branch information
pakrym-stripe committed Nov 8, 2022
1 parent a5684d3 commit e9ce7f2
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,10 +161,9 @@ const utils = {
if (args.length > 0) {
const arg = args[args.length - 1];
if (typeof arg === 'string') {
args.pop();
opts.auth = arg;
opts.auth = args.pop() as string;
} else if (utils.isOptionsHash(arg)) {
const params = {...(arg as Record<string, unknown>)};
const params = {...(args.pop() as Record<string, unknown>)};

const extraKeys = Object.keys(params).filter(
(key) => !OPTIONS_KEYS.includes(key)
Expand Down

0 comments on commit e9ce7f2

Please sign in to comment.