mirror of
https://github.com/silverstripe/silverstripe-versionfeed
synced 2024-10-22 09:05:31 +00:00
DEP PHP Support in CMS5 (#77)
This commit is contained in:
parent
48220dad3a
commit
9b92ba8d6c
@ -16,14 +16,14 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": "^7.4 || ^8.0",
|
||||
"silverstripe/cms": "^4",
|
||||
"silverstripe/versioned": "^1",
|
||||
"silverstripe/siteconfig": "^4"
|
||||
"php": "^8.1",
|
||||
"silverstripe/cms": "^5",
|
||||
"silverstripe/versioned": "^2",
|
||||
"silverstripe/siteconfig": "^5"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^9.5",
|
||||
"squizlabs/php_codesniffer": "^3.0"
|
||||
"squizlabs/php_codesniffer": "^3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
@ -80,7 +80,7 @@ class VersionFeed extends SiteTreeExtension
|
||||
$qLimit = (int)$limit + 1;
|
||||
$versions = $this->owner->Versions(
|
||||
"\"WasPublished\"='1' AND \"CanViewType\" IN ('Anyone', 'Inherit') $offset",
|
||||
"\"SiteTree\".\"LastEdited\" DESC, \"SiteTree\".\"ID\" DESC",
|
||||
"\"LastEdited\" DESC, \"ID\" DESC",
|
||||
$qLimit
|
||||
);
|
||||
|
||||
|
@ -114,7 +114,6 @@ class VersionFeedController extends Extension
|
||||
AND ("PublicHistory" IS NULL OR "PublicHistory" = \'1\')
|
||||
ORDER BY "LastEdited" DESC LIMIT ' . $limit);
|
||||
$lastChange = $latestChanges->record();
|
||||
$latestChanges->rewind();
|
||||
|
||||
if ($lastChange) {
|
||||
// Cache the diffs to remove DOS possibility.
|
||||
|
Loading…
x
Reference in New Issue
Block a user