diff --git a/CHANGELOG.md b/CHANGELOG.md index f621e4f9e..23861a918 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +# v1.7.0-beta.2 +## mm/dd/2019 + +1. [](#new) + # v1.7.0-beta.1 ## 06/14/2019 @@ -8,6 +13,15 @@ * Updated Symfony Components to 4.3 * Added support for Twig 2.11 (compatible with Twig 1.40+) * Added `$grav->exit()` method to properly terminate the request with a response + * Optimization: Initialize debugbar only after the configuration has been loaded + * Optimization: Combine some early Grav processors into a single one + +# v1.6.11 +## mm/dd/2019 + +1. [](#bugfix) + * Fixed error in `ImageMedium::url()` if the image cache folder does not exist + * Fixed empty form flash name after update # v1.6.10 ## 06/14/2019 @@ -17,8 +31,6 @@ * Removed `Gitter` and `Slack` [#2502](https://github.com/getgrav/grav/issues/2502) * Optimizations for Plugin/Theme loading * Generalized markdown classes so they can be used outside of `Page` scope with a custom `Excerpts` class instance - * Optimization: Initialize debugbar only after the configuration has been loaded - * Optimization: Combine some early Grav processors into a single one * Change minimal port number to 0 (unix socket) [#2452](https://github.com/getgrav/grav/issues/2452) 1. [](#bugfix) * Force question to install demo content in theme update [#2493](https://github.com/getgrav/grav/issues/2493) diff --git a/system/src/Grav/Common/Page/Medium/ImageMedium.php b/system/src/Grav/Common/Page/Medium/ImageMedium.php index ac292191a..936f696a9 100644 --- a/system/src/Grav/Common/Page/Medium/ImageMedium.php +++ b/system/src/Grav/Common/Page/Medium/ImageMedium.php @@ -170,8 +170,7 @@ class ImageMedium extends Medium { /** @var UniformResourceLocator $locator */ $locator = Grav::instance()['locator']; - $image_path = $locator->findResource('cache://images', true); - $image_dir = $locator->findResource('cache://images', false); + $image_path = $locator->findResource('cache://images', true) ?: $locator->findResource('cache://images', true, true); $saved_image_path = $this->saveImage(); $output = preg_replace('|^' . preg_quote(GRAV_ROOT, '|') . '|', '', $saved_image_path); @@ -181,6 +180,7 @@ class ImageMedium extends Medium } if (Utils::startsWith($output, $image_path)) { + $image_dir = $locator->findResource('cache://images', false); $output = '/' . $image_dir . preg_replace('|^' . preg_quote($image_path, '|') . '|', '', $output); } diff --git a/system/src/Grav/Framework/Form/FormFlash.php b/system/src/Grav/Framework/Form/FormFlash.php index 50607822c..75ce6ebd3 100644 --- a/system/src/Grav/Framework/Form/FormFlash.php +++ b/system/src/Grav/Framework/Form/FormFlash.php @@ -66,7 +66,7 @@ class FormFlash implements \JsonSerializable } catch (\Exception $e) { $data = []; } - $this->formName = null !== $formName ? $content['form'] ?? '' : ''; + $this->formName = $content['form'] ?? $formName; $this->url = $data['url'] ?? ''; $this->user = $data['user'] ?? null; $this->data = $data['data'] ?? null;