Skip to content

Commit 1a1fbfe

Browse files
committed
Remove unused field.
1 parent cdc0c7b commit 1a1fbfe

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

lib/src/main/java/com/diffplug/spotless/LineEnding.java

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,8 @@
1919
import java.io.Serializable;
2020
import java.lang.reflect.Method;
2121
import java.util.Objects;
22-
import java.util.function.BiFunction;
2322
import java.util.function.Supplier;
2423

25-
import javax.annotation.Nullable;
26-
2724
/**
2825
* Represents the line endings which should be written by the tool.
2926
*/
@@ -76,16 +73,14 @@ public Policy createPolicy(File projectDir, Supplier<Iterable<File>> toFormat) {
7673
}
7774
}
7875

79-
private static volatile @Nullable BiFunction<File, Supplier<Iterable<File>>, Policy> gitAttributesPolicyCreator;
80-
8176
// @formatter:off
8277
/** Should use {@link #createPolicy(File, Supplier)} instead, but this will work iff its a path-independent LineEnding policy. */
8378
public Policy createPolicy() {
8479
switch (this) {
8580
case PLATFORM_NATIVE: return _platformNativePolicy;
8681
case WINDOWS: return WINDOWS_POLICY;
8782
case UNIX: return UNIX_POLICY;
88-
case MAC_CLASSIC: return MAC_CLASSIC_POLICY;
83+
case MAC_CLASSIC: return MAC_CLASSIC_POLICY;
8984
default: throw new UnsupportedOperationException(this + " is a path-specific line ending.");
9085
}
9186
}
@@ -129,7 +124,7 @@ public String str() {
129124
case PLATFORM_NATIVE: return _platformNative;
130125
case WINDOWS: return "\r\n";
131126
case UNIX: return "\n";
132-
case MAC_CLASSIC: return "\r";
127+
case MAC_CLASSIC: return "\r";
133128
default: throw new UnsupportedOperationException(this + " is a path-specific line ending.");
134129
}
135130
}

0 commit comments

Comments
 (0)