Skip to content

Commit

Permalink
fix: convert command arguments to string if not undefined
Browse files Browse the repository at this point in the history
Close #33
  • Loading branch information
robingenz committed Jan 29, 2025
1 parent 7a5f4fe commit b147e21
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/commands/apps/bundles/create.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,21 +80,21 @@ export default defineCommand({
process.exit(1);
}

let androidMax = ctx.args.androidMax as string | undefined;
let androidMin = ctx.args.androidMin as string | undefined;
let androidMax = ctx.args.androidMax === undefined ? undefined : ctx.args.androidMax + ''; // Convert to string
let androidMin = ctx.args.androidMin === undefined ? undefined : ctx.args.androidMin + ''; // Convert to string
let appId = ctx.args.appId as string | undefined;
let artifactType =
ctx.args.artifactType === 'manifest' || ctx.args.artifactType === 'zip'
? ctx.args.artifactType
: ('zip' as 'manifest' | 'zip');
let channelName = ctx.args.channel as string | undefined;
let customProperty = ctx.args.customProperty as string | string[] | undefined;
let expiresInDays = ctx.args.expiresInDays as string | undefined;
let iosMax = ctx.args.iosMax as string | undefined;
let iosMin = ctx.args.iosMin as string | undefined;
let expiresInDays = ctx.args.expiresInDays === undefined ? undefined : ctx.args.expiresInDays + ''; // Convert to string
let iosMax = ctx.args.iosMax === undefined ? undefined : ctx.args.iosMax + ''; // Convert to string
let iosMin = ctx.args.iosMin === undefined ? undefined : ctx.args.iosMin + ''; // Convert to string
let path = ctx.args.path as string | undefined;
let privateKey = ctx.args.privateKey as string | undefined;
let rolloutAsString = ctx.args.rollout as string | undefined;
let rolloutAsString = ctx.args.rollout === undefined ? undefined : ctx.args.rollout + ''; // Convert to string
let url = ctx.args.url as string | undefined;
// Validate the expiration days
let expiresAt: string | undefined;
Expand Down

0 comments on commit b147e21

Please sign in to comment.