fix directory redirects

Este commit está contenido en:
AJ ONeal 2020-11-11 17:47:50 -07:00
padre b0a56bec64
commit 706111f8ba
Se han modificado 1 ficheros con 6 adiciones y 0 borrados

Ver fichero

@ -1038,6 +1038,12 @@
// TODO why are redirects broken?
var redirectHtml = Mustache.render(desi.partials.redirect, view);
entity.redirects.forEach(function (redirect) {
if ("" === path.extname(redirect)) {
redirect += "/";
}
if ("/" === redirect[redirect.length - 1]) {
redirect += "index.html";
}
compiled.push({
contents: redirectHtml,
path: redirect,