private function getFrontmatter($file)
    {
        $basepath = $this->config["basePath"];
        $filter1  = $this->config["textfilter-frontmatter"];
        $filter2  = $this->config["textfilter-title"];
        $filter = array_merge($filter1, $filter2);
        
        $path = $basepath . "/" . $file;
        $src = file_get_contents($path);
        $filtered = $this->di->get("textfilter")->parse($src, $filter);
        return $filtered->frontmatter;
    }