public function register($slug, $nameSingular, $namePlural, $description, $supports = array(), $icon = null, $plugin = null, $cache_ttl = 0, $hideTitle = false)
    {
        //\Modularity\Helper\Wp::deprecatedFunction('Function $module->' . __FUNCTION__ . ' is deprecated since Modularity version 2.0.0');

        if (empty($slug)) {
            return;
        }

        add_action('Modularity/Init', function ($moduleManager) use ($slug, $nameSingular, $namePlural, $description, $supports, $icon, $plugin, $cache_ttl, $hideTitle) {
            $module = new \Modularity\Module();
            $module->slug = $slug;
            $module->nameSingular = $nameSingular;
            $module->namePlural = $namePlural;
            $module->description = $description;
            $module->supports = $supports;
            $module->icon = $icon;
            $module->plugin = $plugin;
            $module->cacheTtl = $cache_ttl;
            $module->hideTitle = $hideTitle;
            $module->isDeprecated = $this->isDeprecated;
            $module->ghost = true;

            $class = get_class($this);
            $class = explode('\\', $class);
            $moduleManager->register($module, MODULARITY_PATH . 'source/php/Module/' . end($class));
        });
    }