mirror of
https://github.com/getgrav/grav.git
synced 2026-03-18 02:21:11 +01:00
Fix renaming the folder name if the page, in the default language, had a custom slug set in its header
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
1. [](#bugfix)
|
||||
* Fixed cross volume file system operations [#635](https://github.com/getgrav/grav/issues/635)
|
||||
* Fix issue with pages folders validation not accepting uppercase letters
|
||||
* Fix renaming the folder name if the page, in the default language, had a custom slug set in its header
|
||||
|
||||
# v1.1.12
|
||||
## 12/26/2016
|
||||
|
||||
@@ -1458,8 +1458,11 @@ class Page
|
||||
{
|
||||
if ($var !== null) {
|
||||
$order = !empty($var) ? sprintf('%02d.', (int)$var) : '';
|
||||
$this->folder($order . $this->slug());
|
||||
$this->folder($order . preg_replace(PAGE_ORDER_PREFIX_REGEX, '', $this->folder));
|
||||
|
||||
return $order;
|
||||
}
|
||||
|
||||
preg_match(PAGE_ORDER_PREFIX_REGEX, $this->folder, $order);
|
||||
|
||||
return isset($order[0]) ? $order[0] : false;
|
||||
|
||||
Reference in New Issue
Block a user