public function all($onlyEnabled = false)
    {
        $themes = $this->repository->findAll();

        if ($onlyEnabled) {
            $themes = array_filter($themes, function ($theme) {
                return $theme->isEnabled();
            });

            $pm = $this->pm;
            //then according to plugins

            $themes = array_filter($themes, function ($theme) use ($pm) {
                return $pm->isLoaded($theme->getPlugin());
            });
        }

        return $themes;
    }