diff options
author | Luck <git@lucko.me> | 2020-02-06 14:22:11 +0000 |
---|---|---|
committer | Luck <git@lucko.me> | 2020-02-06 14:22:11 +0000 |
commit | ef810759468c84668136932bdddf2c04db09fd08 (patch) | |
tree | 923677dbd5a4c26ab7f3a53a33731af4926b87ce /spark-common | |
parent | e02d52ce8d45550a4d77f11971e31cf0732e5f0c (diff) | |
download | spark-ef810759468c84668136932bdddf2c04db09fd08.tar.gz spark-ef810759468c84668136932bdddf2c04db09fd08.tar.bz2 spark-ef810759468c84668136932bdddf2c04db09fd08.zip |
Ignore expired log entries on load
Diffstat (limited to 'spark-common')
-rw-r--r-- | spark-common/src/main/java/me/lucko/spark/common/activitylog/ActivityLog.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/spark-common/src/main/java/me/lucko/spark/common/activitylog/ActivityLog.java b/spark-common/src/main/java/me/lucko/spark/common/activitylog/ActivityLog.java index 894593c..6962400 100644 --- a/spark-common/src/main/java/me/lucko/spark/common/activitylog/ActivityLog.java +++ b/spark-common/src/main/java/me/lucko/spark/common/activitylog/ActivityLog.java @@ -114,8 +114,9 @@ public class ActivityLog { Activity activity = Activity.deserialize(element); if (activity.shouldExpire()) { save = true; + } else { + this.log.add(activity); } - this.log.add(activity); } catch (Exception e) { e.printStackTrace(); } |