Make the jail stick manager/creation smarter and fix jailing via jail

sticks, as it wasn't working at all.
This commit is contained in:
graywolf336
2014-07-15 01:05:46 -05:00
parent d034a0f1ed
commit 8a7a9cefef
7 changed files with 77 additions and 94 deletions

View File

@ -101,7 +101,7 @@ public class JailManager {
* @return The {@link Jail} with the given name, if no jail found this <strong>will</strong> return null.
*/
public Jail getJail(String name) {
return this.jails.get(name);
return name.isEmpty() ? this.jails.values().iterator().next() : this.jails.get(name);
}
/**