Skip to content

Commit

Permalink
Merge pull request #56 from mainmatter/pichfl/fix-no-devDeps
Browse files Browse the repository at this point in the history
Bugfix: Don't crash when devDependencies are not defined
  • Loading branch information
pichfl authored Jan 7, 2025
2 parents 41c48f1 + fd384be commit e559701
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/common-utils.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ function getPackageJson(cwd = process.cwd()) {
function getThemePackage() {
const packageJson = getPackageJson();
return [
...Object.keys(packageJson.dependencies),
...Object.keys(packageJson.devDependencies),
...Object.keys(packageJson.dependencies ?? {}),
...Object.keys(packageJson.devDependencies ?? {}),
].find((name) => name.startsWith('auto-reveal-theme-'));
}

Expand Down

0 comments on commit e559701

Please sign in to comment.