ASSET-PathPackage-Enhancement - Use parent getUrl method instead of duplicating code.

This commit is contained in:
tiecoders 2019-04-07 01:25:14 +02:00
parent 50c22b3d58
commit 0c2a2bf536
1 changed files with 1 additions and 5 deletions

View File

@ -53,11 +53,7 @@ class PathPackage extends Package
*/
public function getUrl($path)
{
if ($this->isAbsoluteUrl($path)) {
return $path;
}
$versionedPath = $this->getVersionStrategy()->applyVersion($path);
$versionedPath = parent::getUrl($path);
// if absolute or begins with /, we're done
if ($this->isAbsoluteUrl($versionedPath) || ($versionedPath && '/' === $versionedPath[0])) {