Skip to content

Commit

Permalink
chore: optional type
Browse files Browse the repository at this point in the history
  • Loading branch information
WillieRuemmele committed Jul 19, 2024
1 parent f708a69 commit 12db42d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/SfCommandError.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export class SfCommandError extends SfError {
const aggregator: Array<{ flag: string; args: string[] }> = [];
output.forEach((k, i) => {
let argCounter = i + 1;
if (k.type === 'flag' && output[argCounter].type === 'arg') {
if (k.type === 'flag' && output[argCounter]?.type === 'arg') {
const args: string[] = [];
while (output[argCounter]?.type === 'arg') {
args.push(output[argCounter].input);
Expand Down

0 comments on commit 12db42d

Please sign in to comment.