private function scan($directory, $filename)
    {
        $filename = strtolower($filename);

        foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory)) as $file) {
            if (strtolower($file->getFilename()) == $filename) {
                return $file->getRealPath();
            }
        }

        return null;
    }