Fixed issue with incorrect setting page to be modular #1573

This commit is contained in:
Andy Miller
2019-01-14 11:48:58 -07:00
parent 9a64094683
commit 6d03d638c3
2 changed files with 2 additions and 2 deletions

View File

@@ -9,6 +9,7 @@
* v.1.8.16 fixes merged in
1. [](#bugfix)
* Removed `tabs`, `tab`, and `toggle` fields as they are now in Form plugin
* Fix issue with new page always showing modular page templates [#1573](https://github.com/getgrav/grav-plugin-admin/issues/1573)
# v1.9.0-beta.7
## 12/14/2018

View File

@@ -1476,7 +1476,7 @@ class Admin
$pages->addPage($page, $path);
// Set if Modular
$page->modularTwig($slug[0] ?? '' === '_');
$page->modularTwig($slug[0] === '_');
// Determine page type.
if (isset($this->session->{$page->route()})) {
@@ -1524,7 +1524,6 @@ class Admin
$page->name($type . CONTENT_EXT);
$page->header();
}
$page->modularTwig($slug[0] ?? '' === '_');
}
return $page;