mirror of
https://github.com/FabricMC/fabric.git
synced 2025-03-24 22:11:18 -04:00
[fabric-resource-loader] make paulscode hack opt-in, possibly remove in the future; i mean, no paulscode anymore
This commit is contained in:
parent
945f265fc3
commit
eff4f58df6
2 changed files with 6 additions and 4 deletions
fabric-resource-loader-v0
|
@ -1,2 +1,2 @@
|
|||
archivesBaseName = "fabric-resource-loader-v0"
|
||||
version = getSubprojectVersion(project, "0.1.0")
|
||||
version = getSubprojectVersion(project, "0.1.1")
|
||||
|
|
|
@ -22,11 +22,13 @@ import java.io.IOException;
|
|||
import java.util.concurrent.*;
|
||||
|
||||
class DeferredNioExecutionHandler {
|
||||
private static final ThreadLocal<Boolean> DEFERRED_REQUIRED = new ThreadLocal<>();
|
||||
// private static final ThreadLocal<Boolean> DEFERRED_REQUIRED = new ThreadLocal<>();
|
||||
private static final boolean DEFER_REQUESTED = System.getProperty("fabric.resource-loader.deferFilesystemOperations", "false").equalsIgnoreCase("true");
|
||||
private static ExecutorService EXECUTOR_SERVICE;
|
||||
|
||||
public static boolean shouldDefer() {
|
||||
Boolean deferRequired = DEFERRED_REQUIRED.get();
|
||||
return DEFER_REQUESTED;
|
||||
/* Boolean deferRequired = DEFERRED_REQUIRED.get();
|
||||
if (deferRequired == null) {
|
||||
deferRequired = false;
|
||||
|
||||
|
@ -41,7 +43,7 @@ class DeferredNioExecutionHandler {
|
|||
DEFERRED_REQUIRED.set(deferRequired);
|
||||
}
|
||||
|
||||
return deferRequired;
|
||||
return deferRequired; */
|
||||
}
|
||||
|
||||
public static <V> V submit(Callable<V> callable, boolean cond) throws IOException {
|
||||
|
|
Loading…
Add table
Reference in a new issue