Skip to content

Commit 7456b65

Browse files
committed
simplify canister file check
1 parent 2c0478b commit 7456b65

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

crates/icp/src/project.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -175,14 +175,7 @@ pub async fn consolidate_manifest(
175175
// For explicit paths, validate that they exist and contain canister.yaml
176176
let mut validated_paths = vec![];
177177
for p in paths {
178-
if !p.is_dir() {
179-
return NotFoundSnafu {
180-
kind: "canister".to_string(),
181-
path: pattern.to_string(),
182-
}
183-
.fail();
184-
}
185-
if !p.join(CANISTER_MANIFEST).exists() {
178+
if !p.join(CANISTER_MANIFEST).is_file() {
186179
return NotFoundSnafu {
187180
kind: "canister".to_string(),
188181
path: pattern.to_string(),

0 commit comments

Comments
 (0)