1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-18 10:51:21 +02:00

Flextype Core: Entries #175 #165

- Collections implementation - next round
This commit is contained in:
Awilum
2019-07-03 15:45:40 +03:00
parent 486bfd3138
commit 8acf7b0383

View File

@@ -70,7 +70,7 @@ class Entries
// Create unique entry cache_id
// Entry Cache ID = entry + entry file + entry file time stamp
$entry_cache_id = md5('entry' . $entry_file . ((Filesystem::getTimestamp($entry_file)) ? Filesystem::getTimestamp($entry_file) : '') );
$entry_cache_id = md5('entry' . $entry_file . Filesystem::getTimestamp($entry_file));
// Try to get the requested entry from cache
if ($this->flextype['cache']->contains($entry_cache_id)) {
@@ -226,7 +226,7 @@ class Entries
// ignore ...
} else {
if ($current_entry['type'] == 'dir' && Filesystem::has($current_entry['path'] . '/entry.json')) {
$_entries_ids .= 'entry:' . ltrim(rtrim(str_replace(PATH['entries'], '', $current_entry['path']), '/'), '/') . ' timestamp:' . ((Filesystem::getTimestamp($current_entry['path'] . '/entry.json')) ? Filesystem::getTimestamp($current_entry['path'] . '/entry.json') : '') . ' ';
$_entries_ids .= 'entry:' . ltrim(rtrim(str_replace(PATH['entries'], '', $current_entry['path']), '/'), '/') . ' timestamp:' . Filesystem::getTimestamp($current_entry['path'] . '/entry.json') . ' ';
}
}
}