fix: do not generate empty file when use ts without router (#4374)

(cherry picked from commit 52bae8e14a)
This commit is contained in:
Cédric Exbrayat
2019-07-30 10:42:00 +02:00
committed by Haoqun Jiang
parent bb2e3e7217
commit 7c19dd61e2
2 changed files with 19 additions and 1 deletions
+1 -1
View File
@@ -412,7 +412,7 @@ function renderFile (name, data, ejsOptions) {
// if evaluated to falsy value, return early to avoid extra cost for extend expression
const result = ejs.render(finalTemplate, data, ejsOptions)
if (!result) {
return
return ''
}
}