From fecaf76acfde9223b0066c6a01dc51a19b95c766 Mon Sep 17 00:00:00 2001 From: Steve Anton Date: Wed, 10 Apr 2013 16:30:30 -0700 Subject: [PATCH] Initialize depends set to an empty set to prevent a NPE when no depends given. --- .../net/md_5/bungee/api/plugin/PluginDescription.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/api/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java b/api/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java index 9c9daa74..4ecab7cc 100644 --- a/api/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java +++ b/api/src/main/java/net/md_5/bungee/api/plugin/PluginDescription.java @@ -1,13 +1,16 @@ package net.md_5.bungee.api.plugin; +import java.util.HashSet; import java.util.Set; import lombok.AllArgsConstructor; import lombok.Data; +import lombok.NoArgsConstructor; /** * POJO representing the plugin.yml file. */ @Data +@NoArgsConstructor @AllArgsConstructor public class PluginDescription { @@ -31,9 +34,5 @@ public class PluginDescription /** * Plugin hard dependencies. */ - private Set depends; - - public PluginDescription() - { - } + private Set depends = new HashSet<>(); }