Skip to content

Commit

Permalink
Fixed StaticOptionalConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
WillFP committed Apr 2, 2021
1 parent 45c53b9 commit 9565ab0
Showing 1 changed file with 17 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import org.bukkit.configuration.file.YamlConfiguration;
import org.jetbrains.annotations.NotNull;

public abstract class StaticOptionalConfig extends AbstractUndefinedConfig {
public abstract class StaticOptionalConfig extends AbstractUndefinedConfig<YamlConfiguration> {
/**
* Config implementation for passing YamlConfigurations.
* <p>
Expand All @@ -14,11 +14,26 @@ public abstract class StaticOptionalConfig extends AbstractUndefinedConfig {
* @param configName The name of the config
* @param plugin The plugin.
* @param config The YamlConfiguration handle.
* @deprecated Plugin not required.
*/
@Deprecated
public StaticOptionalConfig(@NotNull final String configName,
@NotNull final AbstractEcoPlugin plugin,
@NotNull final YamlConfiguration config) {
super(configName, plugin);
this(configName, config);
}

/**
* Config implementation for passing YamlConfigurations.
* <p>
* Does not automatically update.
*
* @param configName The name of the config
* @param config The YamlConfiguration handle.
*/
public StaticOptionalConfig(@NotNull final String configName,
@NotNull final YamlConfiguration config) {
super(configName);

init(config);
}
Expand Down

0 comments on commit 9565ab0

Please sign in to comment.