ASSET-PathPackage-Enhancement - Use parent getUrl method instead of duplicating code.
This commit is contained in:
parent
50c22b3d58
commit
0c2a2bf536
@ -53,11 +53,7 @@ class PathPackage extends Package
|
|||||||
*/
|
*/
|
||||||
public function getUrl($path)
|
public function getUrl($path)
|
||||||
{
|
{
|
||||||
if ($this->isAbsoluteUrl($path)) {
|
$versionedPath = parent::getUrl($path);
|
||||||
return $path;
|
|
||||||
}
|
|
||||||
|
|
||||||
$versionedPath = $this->getVersionStrategy()->applyVersion($path);
|
|
||||||
|
|
||||||
// if absolute or begins with /, we're done
|
// if absolute or begins with /, we're done
|
||||||
if ($this->isAbsoluteUrl($versionedPath) || ($versionedPath && '/' === $versionedPath[0])) {
|
if ($this->isAbsoluteUrl($versionedPath) || ($versionedPath && '/' === $versionedPath[0])) {
|
||||||
|
Reference in New Issue
Block a user