$dependentAsset =
$assetMapper->
getAsset($resolvedPath);
if (null ===
$dependentAsset) { $this->
handleMissingImport(sprintf('Unable to find asset "%s" referenced in "%s".',
$matches[1
],
$asset->sourcePath
));
// return original, unchanged path
return $matches[0
];
} $asset->
addDependency(new AssetDependency($dependentAsset));
$relativePath =
$this->
createRelativePath($asset->publicPathWithoutDigest,
$dependentAsset->publicPath
);
return 'url("'.
$relativePath.'")';
},
$content);
} public function supports(MappedAsset
$asset): bool
{ return 'css' ===
$asset->publicExtension;
} private function handleMissingImport(string
$message, \Throwable
$e = null
): void
{