MINOR: removed direct access to $_REQUEST and instead encapulsate access through SS_HTTPRequest

This commit is contained in:
Will Rossiter 2011-09-02 13:24:29 +12:00 committed by Ingo Schommer
parent 010829f6fb
commit 803adfce42

View File

@ -357,8 +357,11 @@ JS;
if($id instanceof $treeClass) {
return $id;
} else if($id && is_numeric($id)) {
if(isset($_REQUEST['Version'])) $versionID = (int) $_REQUEST['Version'];
}
else if($id && is_numeric($id)) {
if($this->request->getVar('Version')) {
$versionID = (int) $this->request->getVar('Version');
}
if($versionID) {
$record = Versioned::get_version($treeClass, $id, $versionID);