fix
Helius
2022-08-11 58c4a118bad3d33a553915781c9711d7bf2f6ee2
src/main/java/com/xcong/farmer/cms/core/template/TemplateConfiguration.java
@@ -1,5 +1,6 @@
package com.xcong.farmer.cms.core.template;
import com.xcong.farmer.cms.common.exception.GlobalException;
import com.xcong.farmer.cms.common.utils.FileUtils;
import com.xcong.farmer.cms.core.node.PartNode;
import com.xcong.farmer.cms.core.node.Template;
@@ -54,7 +55,13 @@
    }
    public Template template(String templatePath, String templateName) {
        return template(new File(path(templatePath) + templateName));
        File file = new File(path(templatePath) + templateName);
        if (!file.exists()) {
            log.info("模板文件不存在 : {}", templateName);
            throw new GlobalException("模板文件不存在:" + templateName);
        }
        return template(file);
    }
    public Template template(File file) {