From 132d0cf578625d7daf14d78e6b7ac3cccfcf323c Mon Sep 17 00:00:00 2001 From: Luck Date: Fri, 7 Apr 2017 19:59:53 +0100 Subject: [PATCH] Fix export command switchprimarygroup output, and log player uuid if their username isn't included --- api/src/main/java/me/lucko/luckperms/api/LogEntry.java | 2 +- .../src/main/java/me/lucko/luckperms/common/data/Exporter.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/api/src/main/java/me/lucko/luckperms/api/LogEntry.java b/api/src/main/java/me/lucko/luckperms/api/LogEntry.java index cb5efa3a1..46cfcf6c1 100644 --- a/api/src/main/java/me/lucko/luckperms/api/LogEntry.java +++ b/api/src/main/java/me/lucko/luckperms/api/LogEntry.java @@ -90,7 +90,7 @@ public class LogEntry implements Comparable { public String getFormatted() { return String.format(FORMAT, - actorName, + String.valueOf(actorName).equals("null") ? actor.toString() : actorName, Character.toString(type), actedName, action diff --git a/common/src/main/java/me/lucko/luckperms/common/data/Exporter.java b/common/src/main/java/me/lucko/luckperms/common/data/Exporter.java index 4146bc490..99ec3e8e1 100644 --- a/common/src/main/java/me/lucko/luckperms/common/data/Exporter.java +++ b/common/src/main/java/me/lucko/luckperms/common/data/Exporter.java @@ -227,7 +227,7 @@ public class Exporter implements Runnable { } if (!user.getPrimaryGroup().getStoredValue().equalsIgnoreCase("default")) { - output.add("/luckperms user " + user.getUuid().toString() + " switchprimarygroup " + user.getPrimaryGroup()); + output.add("/luckperms user " + user.getUuid().toString() + " switchprimarygroup " + user.getPrimaryGroup().getStoredValue()); } if (!inDefault) {