@Override
    public void onEnable() {
        instance = this;
        ProtocolManager protocolManager = ProtocolLibrary.getProtocolManager();

        ConfigurationSerialization.registerClass(PlayerConfiguration.class, "PlayerConfig");
        //noinspection unchecked
        censorWords = (List<String>) getConfig().getList("censor.words");
        enabledByDefault = getConfig().getBoolean("defaults.enabledOnFirstJoin");
        ConfigurationSection section = getConfig().getConfigurationSection("censor.players");
        if (section != null) {
            Map<String, Object> playersTmp = getConfig().getConfigurationSection("censor.players").getValues(false);

            for (Map.Entry<String, Object> entry : playersTmp.entrySet())
                players.put(entry.getKey(), (PlayerConfiguration) entry.getValue());
        }

        getConfig().options().copyDefaults(true);
        saveConfig();
        protocolManager.addPacketListener(new PacketInterceptor(this));

        getCommand("filterme").setExecutor(new CommandCensorToggle());
    }