Fix getRegion for legacy WG 6

This commit is contained in:
Eric 2019-05-31 12:02:21 +02:00
parent 10fe9e2706
commit abcc32bea0

View File

@ -116,7 +116,9 @@ public class WorldGuardImplementation implements IWorldGuardImplementation {
@Override
public Optional<IWrappedRegion> getRegion(World world, String id) {
return getWorldManager(world).map(regionManager -> new WrappedRegion(world, regionManager.getRegion(id)));
return getWorldManager(world)
.map(regionManager -> regionManager.getRegion(id))
.map(region -> new WrappedRegion(world, region));
}
@Override