Skip to content

Commit

Permalink
Fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
dtcooper committed Jan 31, 2024
1 parent eeb9752 commit 0bffa6d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/pi-gen-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,10 @@ export async function validateConfig(config: PiGenConfig): Promise<void> {
}

if (
!/^[0-9]$/.test(config.compressionLevel) &&
deployCompression === 'xz' &&
config.compressionLevel !== '9e'
!(
/^[0-9]$/.test(config.compressionLevel) ||
(deployCompression === 'xz' && config.compressionLevel === '9e')
)
) {
throw new Error('compression-level must be between 0 and 9 (or 9e for xz)')
}
Expand Down

0 comments on commit 0bffa6d

Please sign in to comment.