1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-02-24 08:22:56 +01:00

Merge branch 'groupmanager' of github.com:essentials/Essentials into 2.9

This commit is contained in:
KHobbits 2012-08-31 22:28:21 +01:00
commit 9cd396ebf8
3 changed files with 15 additions and 7 deletions

View File

@ -195,3 +195,5 @@ v 2.0:
- Fix GlobalGroups not loading permission nodes.
- Fix an error with Logging set to 'OFF' triggering a cast exception.
- No more null errors from corrupt config.yml's.
- Give a better error when a subgroup is null.
- Include the GM version when logging errors.

View File

@ -246,7 +246,7 @@ public class GroupManager extends JavaPlugin {
lastError = ex.getMessage();
GroupManager.logger.severe("===================================================");
GroupManager.logger.severe("= ERROR REPORT START =");
GroupManager.logger.severe("= ERROR REPORT START - " + this.getDescription().getVersion() + " =");
GroupManager.logger.severe("===================================================");
GroupManager.logger.severe("=== PLEASE COPY AND PASTE THE ERROR.LOG FROM THE ==");
GroupManager.logger.severe("= GROUPMANAGER FOLDER TO AN ESSENTIALS DEVELOPER =");
@ -258,7 +258,9 @@ public class GroupManager extends JavaPlugin {
// Append this error to the error log.
try {
String error = "=============================== GM ERROR LOG ===============================\n\n";
String error = "=============================== GM ERROR LOG ===============================\n";
error += "= ERROR REPORT START - " + this.getDescription().getVersion() + " =\n\n";
error += Tasks.getStackTraceAsString(ex);
error += "\n============================================================================\n";

View File

@ -861,11 +861,15 @@ public class WorldDataHolder {
*/
} else if (nodeData instanceof List) {
for (Object o : ((List) nodeData)) {
Group subGrp = ph.getGroup(o.toString());
if (subGrp != null) {
thisUser.addSubGroup(subGrp);
if (o == null) {
GroupManager.logger.warning("Invalid Subgroup data for user: " + thisUser.getName() + ". Ignoring entry in file: " + usersFile.getPath());
} else {
GroupManager.logger.warning("Subgroup '" + o.toString() + "' not found for user: " + thisUser.getName() + ". Ignoring entry in file: " + usersFile.getPath());
Group subGrp = ph.getGroup(o.toString());
if (subGrp != null) {
thisUser.addSubGroup(subGrp);
} else {
GroupManager.logger.warning("Subgroup '" + o.toString() + "' not found for user: " + thisUser.getName() + ". Ignoring entry in file: " + usersFile.getPath());
}
}
}
} else if (nodeData instanceof String) {