mirror of
https://github.com/flextype/flextype.git
synced 2025-08-08 14:16:46 +02:00
fix(fields): fix issue with slug field in Entries API #520
This commit is contained in:
@@ -14,7 +14,7 @@ if (flextype('registry')->get('flextype.settings.entries.fields.slug.enabled'))
|
||||
return;
|
||||
}
|
||||
|
||||
$parts = strings(flextype('entries')->getStorage('fetch.id'))->trimSlashes()->segments();
|
||||
$parts = explode('/', ltrim(rtrim(flextype('entries')->getStorage('fetch.id'), '/'), '/'));
|
||||
flextype('entries')->setStorage('fetch.data.slug', (string) end($parts));
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user