Skip to content

Commit 617483f

Browse files
authored
fix(shadcn): do not throw for empty dir (#7196)
* fix(shadcn): do not throw for empty dir * chore: changeset
1 parent 6d2728d commit 617483f

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

.changeset/few-kangaroos-stare.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"shadcn": patch
3+
---
4+
5+
do not throw if empty dir

packages/shadcn/src/utils/get-project-info.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ export async function getTailwindVersion(
154154
cwd: string
155155
): Promise<ProjectInfo["tailwindVersion"]> {
156156
const [packageInfo, config] = await Promise.all([
157-
getPackageInfo(cwd),
157+
getPackageInfo(cwd, false),
158158
getConfig(cwd),
159159
])
160160

0 commit comments

Comments
 (0)