Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

FIXED: Issue where viewing an archived version of a page caused inval…

…id SQL to be generated. This would only occur with subclasses of Page.
  • Loading branch information...
commit 22c5f3129c24ce8b1b39b29012f37f10f23f4893 1 parent 023721a
@tractorcow tractorcow authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  model/Versioned.php
View
2  model/Versioned.php
@@ -154,7 +154,7 @@ function augmentSQL(SQLQuery &$query, DataQuery &$dataQuery = null) {
$query->selectField(sprintf('"%s_versions"."%s"', $baseTable, 'RecordID'), "ID");
if($table != $baseTable) {
- $query->addFrom(array($table => " AND \"{$table}_versions\".\"Version\" = \"{$baseTable}_versions\".\"Version\""));
+ $query->addWhere("\"{$table}_versions\".\"Version\" = \"{$baseTable}_versions\".\"Version\"");
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.