mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge branch '3.2' into 3.3
This commit is contained in:
commit
32f0a637b4
@ -188,7 +188,7 @@ jQuery.noConflict();
|
||||
}
|
||||
|
||||
// Show message (but ignore aborted requests)
|
||||
if(xhr.status !== 0 && msg && $.inArray(msg, ignoredMessages)) {
|
||||
if(xhr.status !== 0 && msg && $.inArray(msg, ignoredMessages) === -1) {
|
||||
// Decode into UTF-8, HTTP headers don't allow multibyte
|
||||
statusMessage(decodeURIComponent(msg), msgType);
|
||||
}
|
||||
|
@ -1451,10 +1451,13 @@ class Versioned extends DataExtension implements TemplateGlobalProvider {
|
||||
*/
|
||||
public function isLatestVersion() {
|
||||
$version = self::get_latest_version($this->owner->class, $this->owner->ID);
|
||||
|
||||
if($version) {
|
||||
return ($version->Version == $this->owner->Version);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the equivalent of a DataList::create() call, querying the latest
|
||||
* version of each page stored in the (class)_versions tables.
|
||||
|
Loading…
Reference in New Issue
Block a user