Skip to content

Commit

Permalink
Pas besoin de revérifier à chaque fois, juste au démarrage suffit
Browse files Browse the repository at this point in the history
  • Loading branch information
Euphillya committed Jan 19, 2024
1 parent 5186ad5 commit b2b9ca3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
6 changes: 3 additions & 3 deletions .idea/sonarlint/issuestore/index.pb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions .idea/sonarlint/securityhotspotstore/index.pb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 7 additions & 5 deletions plugin/src/main/java/fr/euphyllia/skyllia/api/InterneAPI.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,23 +36,25 @@ public class InterneAPI {
private DatabaseLoader databaseLoader;
private Managers managers;
private CacheManager cacheManager;
private boolean useFolia = false;

public InterneAPI(Main plugin) {
this.plugin = plugin;
this.logger = LogManager.getLogger("fr.euphyllia.skyllia.api.InterneAPI");
this.skyblockManager = new SkyblockManager(this.plugin);
this.cacheManager = new CacheManager(this.skyblockManager);
}

public boolean isFolia() {
try {
Class.forName("io.papermc.paper.threadedregions.scheduler.RegionScheduler");
return true;
this.useFolia = true;
} catch (ClassNotFoundException ignored) {
return false;
this.useFolia = false;
}
}

public boolean isFolia() {
return this.useFolia;
}


public @Nullable DatabaseLoader getDatabaseLoader() {
return this.database;
Expand Down

0 comments on commit b2b9ca3

Please sign in to comment.