diff --git a/system/extensions/update-available.ini b/system/extensions/update-available.ini index 56020cd3..bbc8165f 100644 --- a/system/extensions/update-available.ini +++ b/system/extensions/update-available.ini @@ -149,14 +149,14 @@ system/themes/copenhagen.css: copenhagen.css, create, update, careful system/themes/copenhagen.png: copenhagen.png, create Extension: Core -Version: 0.9.11 +Version: 0.9.12 Description: Core functionality of your website. Developer: Anna Svensson Tag: feature DownloadUrl: https://github.com/annaesvensson/yellow-core/archive/refs/heads/main.zip DocumentationUrl: https://github.com/annaesvensson/yellow-core DocumentationLanguage: en, de, sv -Published: 2024-07-22 11:47:55 +Published: 2024-08-28 10:15:04 Status: available system/workers/core.php: core.php, create, update system/extensions/core.php: corepatch.txt, update diff --git a/system/extensions/yellow-extension.ini b/system/extensions/yellow-extension.ini index cc9f610c..2aa49ea1 100755 --- a/system/extensions/yellow-extension.ini +++ b/system/extensions/yellow-extension.ini @@ -1,14 +1,14 @@ # Datenstrom Yellow extension settings Extension: Core -Version: 0.9.11 +Version: 0.9.12 Description: Core functionality of your website. Developer: Anna Svensson Tag: feature DownloadUrl: https://github.com/annaesvensson/yellow-core/archive/refs/heads/main.zip DocumentationUrl: https://github.com/annaesvensson/yellow-core DocumentationLanguage: en, de, sv -Published: 2024-07-22 11:47:55 +Published: 2024-08-28 10:15:04 Status: available system/workers/core.php: core.php, create, update system/extensions/core.php: corepatch.txt, update diff --git a/system/workers/core.php b/system/workers/core.php index 539ffdbf..563447e3 100755 --- a/system/workers/core.php +++ b/system/workers/core.php @@ -2,7 +2,7 @@ // Core extension, https://github.com/annaesvensson/yellow-core class YellowCore { - const VERSION = "0.9.11"; + const VERSION = "0.9.12"; const RELEASE = "0.9"; public $content; // content files public $media; // media files @@ -602,16 +602,17 @@ public function getHomeLocation($location) { // Return parent location public function getParentLocation($location) { + $parentLocation = ""; $token = rtrim($this->yellow->system->get("coreMediaLocation"), "/"); if (preg_match("#^($token.*\/).+?$#", $location, $matches)) { if ($matches[1]!="$token/" || $this->yellow->lookup->isFileLocation($location)) $parentLocation = $matches[1]; } - if (is_string_empty($parentLocation)) $parentLocation = ""; return $parentLocation; } // Return top-level location public function getParentTopLocation($location) { + $parentTopLocation = ""; $token = rtrim($this->yellow->system->get("coreMediaLocation"), "/"); if (preg_match("#^($token.+?\/)#", $location, $matches)) $parentTopLocation = $matches[1]; if (is_string_empty($parentTopLocation)) $parentTopLocation = "$token/";