Make the plugin optional for CommandMapping
This is because we don't necessarily know the plugin or mod that registers a command via Brigadier
import org.spongepowered.api.command.registrar.CommandRegistrar;
import org.spongepowered.plugin.PluginContainer;
+import java.util.Optional;
import java.util.Set;
/**
Set<String> allAliases();
/**
- * Gets the plugin that owns the command.
+ * Gets the plugin that owns the command, if known.
*
* @return The plugin.
*/
- PluginContainer plugin();
+ Optional<PluginContainer> plugin();
/**
* Gets the {@link CommandRegistrar} that registered this command.
