public function getMeta(array $meta = [])
{
if ($this->meta) {
return array_merge($meta, $this->meta);
}
$title = Title::parse($this->getContent()) ?: ucfirst($this->getName());
$default = ['id' => md5($this->getContent() . $this->getRealPath()), 'class' => preg_replace('/[.]/', '', strtolower($this->getName())), 'title' => $title, 'order' => $title, 'date' => $this->isFile() || $this->isDir() ? $this->getCTime() : null, 'created' => $this->isFile() || $this->isDir() ? $this->getCTime() : null, 'access' => $this->isFile() || $this->isDir() ? $this->getATime() : null, 'name' => $this->getName(), 'basename' => $this->getFilename(), 'dir' => $this->isDir() ? $this->getDir() : null, 'file' => $this->isFile() ? $this->getRealPath() : null];
$parsed = (array) Metadata::parse($this->getContent());
return filter(self::class . '::' . __FUNCTION__, array_merge($default, $meta, $parsed), $default, $meta, $parsed);
}