Skip to content

Commit 1e3aa1d

Browse files
committed
fix: ignore undefined appDir when listing sites
Not all sites need to have an associated app directory. The case when they didn't was causing an error to be thrown.
1 parent f0cf652 commit 1e3aa1d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/commands/sites.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export async function listSites(args = {}) {
4343
formatDate(domain.created_at).split(',')[0],
4444
domain.protected ? chalk.red('Yes') : chalk.green('No'),
4545
// domain.owner['username'],
46-
appDir.length == 6?`${appDir[0]}-...-${appDir.slice(-1)}`:appDir.join('-')
46+
appDir && (appDir.length == 6?`${appDir[0]}-...-${appDir.slice(-1)}`:appDir.join('-'))
4747
]);
4848
});
4949

0 commit comments

Comments
 (0)