diff options
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/utils')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/utils/repopatterns/RepoPatternManager.kt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/utils/repopatterns/RepoPatternManager.kt b/src/main/java/at/hannibal2/skyhanni/utils/repopatterns/RepoPatternManager.kt index 27ceb7181..97f9196f2 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/repopatterns/RepoPatternManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/repopatterns/RepoPatternManager.kt @@ -8,6 +8,7 @@ import at.hannibal2.skyhanni.events.LorenzEvent import at.hannibal2.skyhanni.events.PreInitFinishedEvent import at.hannibal2.skyhanni.events.RepositoryReloadEvent import at.hannibal2.skyhanni.utils.ConditionalUtils.afterChange +import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.StringUtils.matches import net.minecraft.launchwrapper.Launch import net.minecraftforge.fml.common.FMLCommonHandler @@ -57,6 +58,8 @@ object RepoPatternManager { } } + val localLoading: Boolean get() = config.forceLocal.get() || LorenzUtils.isInDevEnviromen() + /** * Crash if in a development environment, or if inside a guarded event handler. */ @@ -98,7 +101,7 @@ object RepoPatternManager { */ private fun reloadPatterns() { val remotePatterns = - if (config.forceLocal.get()) mapOf() + if (localLoading) mapOf() else regexes?.regexes ?: mapOf() for (it in usedKeys.values) { |