fix: add checking for missing extensions (#1432)

This commit is contained in:
Jae-Heon Ji 2022-05-24 13:09:01 +09:00 committed by GitHub
parent 9d1d3dac74
commit f7c019743a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -262,7 +262,7 @@ impl LayoutFromYamlIntermediate {
match layout_dir { match layout_dir {
Some(dir) => { Some(dir) => {
let layout_path = &dir.join(layout); let layout_path = &dir.join(layout);
if layout_path.exists() { if layout_path.with_extension("yaml").exists() {
Self::from_path(layout_path) Self::from_path(layout_path)
} else { } else {
LayoutFromYamlIntermediate::from_default_assets(layout) LayoutFromYamlIntermediate::from_default_assets(layout)