private void InnerPostProcess(IAsset asset, CssAutoprefixer cssAutoprefixer) { string newContent; string assetUrl = asset.Url; IList <string> dependencies; try { AutoprefixingResult result = cssAutoprefixer.Process(asset.Content, asset.Url); newContent = result.ProcessedContent; dependencies = result.IncludedFilePaths; } catch (CssAutoprefixingException e) { throw new AssetPostProcessingException( string.Format(CoreStrings.PostProcessors_PostprocessingSyntaxError, CODE_TYPE, assetUrl, POSTPROCESSOR_NAME, e.Message)); } catch (Exception e) { throw new AssetPostProcessingException( string.Format(CoreStrings.PostProcessors_PostprocessingFailed, CODE_TYPE, assetUrl, POSTPROCESSOR_NAME, e.Message), e); } asset.Content = newContent; asset.VirtualPathDependencies = asset.VirtualPathDependencies.Union(dependencies).ToList(); }
private void InnerPostProcess(IAsset asset, CssAutoprefixer cssAutoprefixer) { string newContent; string assetUrl = asset.Url; try { newContent = cssAutoprefixer.Process(asset.Content, asset.Url); } catch (CssAutoprefixingException e) { throw new AssetPostProcessingException( string.Format(CoreStrings.PostProcessors_PostprocessingSyntaxError, CODE_TYPE, assetUrl, POSTPROCESSOR_NAME, e.Message)); } catch (Exception e) { throw new AssetPostProcessingException( string.Format(CoreStrings.PostProcessors_PostprocessingFailed, CODE_TYPE, assetUrl, POSTPROCESSOR_NAME, e.Message), e); } asset.Content = newContent; }