From b713ccff10ef83f7a4a5b5216aec805f05546479 Mon Sep 17 00:00:00 2001 From: md_5 Date: Thu, 19 Dec 2013 19:30:24 +1100 Subject: [PATCH] Validate forced hosts config on reload --- proxy/src/main/java/net/md_5/bungee/conf/Configuration.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/proxy/src/main/java/net/md_5/bungee/conf/Configuration.java b/proxy/src/main/java/net/md_5/bungee/conf/Configuration.java index 854042b8c..6aedbfd76 100644 --- a/proxy/src/main/java/net/md_5/bungee/conf/Configuration.java +++ b/proxy/src/main/java/net/md_5/bungee/conf/Configuration.java @@ -110,6 +110,10 @@ public class Configuration implements ProxyConfig { Preconditions.checkArgument( servers.containsKey( listener.getDefaultServer() ), "Default server %s is not defined", listener.getDefaultServer() ); Preconditions.checkArgument( servers.containsKey( listener.getFallbackServer() ), "Fallback server %s is not defined", listener.getFallbackServer() ); + for ( String server : listener.getForcedHosts().values() ) + { + Preconditions.checkArgument( servers.containsKey( server ), "Forced host server %s is not defined", server ); + } } } }