Skip to content

Commit

Permalink
Always add string paths from args
Browse files Browse the repository at this point in the history
  • Loading branch information
IanVS committed Nov 9, 2023
1 parent bf2edb3 commit 4f41456
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/msw-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -428,11 +428,11 @@ export default class MswConfig {
paths = ['/**', '/'];
} else if (Array.isArray(lastArg)) {
verbs = lastArg;
// Need to loop because TS doesn't know if they're strings or arrays
for (const arg of args) {
if (typeof arg === 'string') {
paths.push(arg);
}
}
// Need to loop because TS doesn't know if they're strings or arrays
for (const arg of args) {
if (typeof arg === 'string') {
paths.push(arg);
}
}

Expand Down

0 comments on commit 4f41456

Please sign in to comment.