public function getContentTypeFromAlias($alias, $forceSlug = false)
    {
        foreach ($this->contenttypes->getData() as $key => $contenttype) {
            if ($forceSlug && $forceSlug === 'singular') {
                if (isset($contenttype['singular_slug']) && ($contenttype['slug'] === $alias || $contenttype['tablename'] === $alias)) {
                    return $contenttype['singular_slug'];
                }
            } elseif ($forceSlug) {
                if (isset($contenttype['slug']) && ($contenttype['slug'] === $alias || $contenttype['tablename'] === $alias)) {
                    return $contenttype['slug'];
                }
            }
            if (isset($contenttype['tablename']) && $contenttype['tablename'] === $alias) {
                return $key;
            }

            if (isset($contenttype['slug']) && $contenttype['slug'] === $alias) {
                return $key;
            }
        }

        return $alias;
    }