mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
apply formatter
This commit is contained in:
@@ -12,8 +12,7 @@ import ro.isdc.wro.model.resource.processor.impl.css.CssImportPreProcessor;
|
||||
public class SassImportProcessor extends CssImportPreProcessor {
|
||||
|
||||
@Override
|
||||
protected String doTransform(String cssContent, List<Resource> foundImports)
|
||||
throws IOException {
|
||||
protected String doTransform(String cssContent, List<Resource> foundImports) throws IOException {
|
||||
for (Resource resource : foundImports) {
|
||||
String uri = resource.getUri();
|
||||
int lastSlash = uri.lastIndexOf('/');
|
||||
|
||||
@@ -15,10 +15,8 @@ import ro.isdc.wro.model.resource.SupportedResourceType;
|
||||
public class SassOnlyProcessor extends RubySassCssProcessor {
|
||||
|
||||
@Override
|
||||
public void process(Resource resource, Reader reader, Writer writer)
|
||||
throws IOException {
|
||||
if (resource.getUri().endsWith(".sass")
|
||||
|| resource.getUri().endsWith(".scss")) {
|
||||
public void process(Resource resource, Reader reader, Writer writer) throws IOException {
|
||||
if (resource.getUri().endsWith(".sass") || resource.getUri().endsWith(".scss")) {
|
||||
super.process(resource, reader, writer);
|
||||
} else {
|
||||
writer.write(IOUtils.toString(reader));
|
||||
|
||||
@@ -17,8 +17,7 @@ public class TimestampProcessor implements ResourcePreProcessor {
|
||||
private static final String NOW = "" + System.currentTimeMillis();
|
||||
|
||||
@Override
|
||||
public void process(Resource resource, Reader reader, Writer writer)
|
||||
throws IOException {
|
||||
public void process(Resource resource, Reader reader, Writer writer) throws IOException {
|
||||
String content = IOUtils.toString(reader);
|
||||
content = content.replace("${timestamp}", NOW);
|
||||
writer.write(content);
|
||||
|
||||
@@ -24,10 +24,8 @@ public abstract class UserCustomCssReference extends ResourceReference {
|
||||
resourceResponse.setTextEncoding("UTF-8");
|
||||
resourceResponse.setWriteCallback(new WriteCallback() {
|
||||
@Override
|
||||
public void writeData(Attributes attributes)
|
||||
throws IOException {
|
||||
attributes.getResponse().write(
|
||||
StringUtils.trimToEmpty(getCss()));
|
||||
public void writeData(Attributes attributes) throws IOException {
|
||||
attributes.getResponse().write(StringUtils.trimToEmpty(getCss()));
|
||||
}
|
||||
});
|
||||
return resourceResponse;
|
||||
|
||||
@@ -10,7 +10,7 @@ import com.google.api.client.util.Maps;
|
||||
|
||||
/**
|
||||
* Build-time solution
|
||||
*
|
||||
*
|
||||
*/
|
||||
public class WroAdditionalProvider implements ProcessorProvider {
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ import ro.isdc.wro.model.resource.processor.ResourcePreProcessor;
|
||||
|
||||
/**
|
||||
* Runtime solution
|
||||
*
|
||||
*
|
||||
*/
|
||||
public class WroManagerFactory extends ConfigurableWroManagerFactory {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user