Merge branch 'IntellectualSites:main' into main

This commit is contained in:
Telesphoreo 2023-07-29 14:15:00 -05:00 committed by GitHub
commit a5b969e1c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 11 deletions

View File

@ -59,7 +59,7 @@ public class UpdateNotification {
Document doc = db.parse(body); Document doc = db.parse(body);
faweVersion = doc.getElementsByTagName("lastSuccessfulBuild").item(0).getFirstChild().getTextContent(); faweVersion = doc.getElementsByTagName("lastSuccessfulBuild").item(0).getFirstChild().getTextContent();
FaweVersion faweVersion = Fawe.instance().getVersion(); FaweVersion faweVersion = Fawe.instance().getVersion();
if (faweVersion.build == 0) { if (faweVersion.build == 0 && !faweVersion.snapshot) {
LOGGER.warn("You are using a snapshot or a custom version of FAWE. This is not an official build distributed " + LOGGER.warn("You are using a snapshot or a custom version of FAWE. This is not an official build distributed " +
"via https://ci.plex.us.org/job/Plex-FAWE/"); "via https://ci.plex.us.org/job/Plex-FAWE/");
return; return;

View File

@ -607,20 +607,17 @@ public final class EditSessionBuilder {
} }
FaweRegionExtent regionExtent = null; FaweRegionExtent regionExtent = null;
if (disallowedRegions != null) { // Always use MultiRegionExtent if we have blacklist regions // Always use MultiRegionExtent if we have blacklist regions
if (allowedRegions != null && allowedRegions.length == 0) {
regionExtent = new NullExtent(this.extent, FaweCache.NO_REGION);
} else if (disallowedRegions != null && disallowedRegions.length != 0) {
regionExtent = new MultiRegionExtent(this.extent, this.limit, allowedRegions, disallowedRegions); regionExtent = new MultiRegionExtent(this.extent, this.limit, allowedRegions, disallowedRegions);
} else if (allowedRegions == null) { } else if (allowedRegions == null) {
allowedRegions = new Region[]{RegionWrapper.GLOBAL()}; allowedRegions = new Region[]{RegionWrapper.GLOBAL()};
} else if (allowedRegions.length == 1) {
regionExtent = new SingleRegionExtent(this.extent, this.limit, allowedRegions[0]);
} else { } else {
if (allowedRegions.length == 0) { regionExtent = new MultiRegionExtent(this.extent, this.limit, allowedRegions, null);
regionExtent = new NullExtent(this.extent, FaweCache.NO_REGION);
} else {
if (allowedRegions.length == 1) {
regionExtent = new SingleRegionExtent(this.extent, this.limit, allowedRegions[0]);
} else {
regionExtent = new MultiRegionExtent(this.extent, this.limit, allowedRegions, null);
}
}
} }
if (regionExtent != null) { if (regionExtent != null) {
if (placeChunks) { if (placeChunks) {