1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-24 21:56:25 +02:00

fix(core): fix update() method #186

This commit is contained in:
Awilum
2019-09-10 22:56:53 +03:00
parent 5a28402e88
commit 889ca8cc13

View File

@@ -373,7 +373,8 @@ class Entries
$entry_file = $this->getFileLocation($id);
if (Filesystem::has($entry_file)) {
$entry = Parser::decode($entry_file, 'frontmatter');
$body = Filesystem::read($entry_file);
$entry = Parser::decode($body, 'frontmatter');
return Filesystem::write($entry_file, Parser::encode(array_replace_recursive($entry, $data), 'frontmatter'));
}