@@ -146,8 +146,7 @@ module.exports = function(crowi, req, locals) {
return false;
};
- locals.isTrashPage = function() {
- const path = req.path || '';
+ locals.isTrashPage = function(path = '') {
if (path.match(/^\/trash(\/.*)?$/)) {
return true;
}
@@ -73,7 +73,8 @@
</div>
{% endif %}
- {% if isTrashPage() %}
+ {{isTrashPage}}
+ {% if isTrashPage(page.path) %}
<div id="trash-page-alert"></div>