- Fixed Memory caching interfacing.

- Fixed a bug within UrlExtension which was triggered only in IIS
This commit is contained in:
Dave Mc Nicoll committed 2020-01-29 16:13:05 -05:00
1 parent ddc3ae704a
commit e8d81222ff
2 files changed
+10 -19

No files matched your search

+5 -5
View File
@@ -15,7 +15,7 @@ class UrlExtension implements Extension {
public array $tokens = [ "url" , "route", "asset" ];
public function __construct(Context $context, string $urlBase = "", string $assetToken = "") {
$this->urlBase = $urlBase;
$this->urlBase = trim($urlBase, "/");
$this->assetToken = $assetToken;
$this->register($context);
}
@@ -110,7 +110,7 @@ class UrlExtension implements Extension {
protected function base() : string
{
return $this->urlBase ? $this->urlBase . "/" : "";
return $this->urlBase ? "/" . $this->urlBase : "";
}
/**
@@ -143,9 +143,9 @@ class UrlExtension implements Extension {
]));
return $header
|| ( "443" === $_SERVER['SERVER_PORT'] ?? "" )
|| ( "https" === $_SERVER['REQUEST_SCHEME'] ?? "http" )
|| ( "off" !== strtolower($_SERVER['HTTPS'] ?? "off") );
|| ( "443" === ( $_SERVER['SERVER_PORT'] ?? "" ) )
|| ( "https" === ( $_SERVER['REQUEST_SCHEME'] ?? "http") )
|| ( "off" !== ( strtolower($_SERVER['HTTPS'] ?? "off")) );
}
protected function prepareRoute(string $route, array &$arguments)