|
@@ 144-147 (lines=4) @@
|
| 141 |
|
$db = \Registry::get('db'); |
| 142 |
|
$m = $this->getMapper(); |
| 143 |
|
$m->load([$db->quotekey($idField) . ' = ?', $id]); |
| 144 |
|
if (null == $m->$idField) { |
| 145 |
|
$this->failure('authentication_error', "Object with @id does not exist.", 404); |
| 146 |
|
return $this->setOAuthError('invalid_request'); |
| 147 |
|
} |
| 148 |
|
|
| 149 |
|
$this->mapper =& $m; |
| 150 |
|
return $m; |
|
@@ 192-195 (lines=4) @@
|
| 189 |
|
$db = \Registry::get('db'); |
| 190 |
|
$m = $this->getMapper(); |
| 191 |
|
$m->load([$db->quotekey($idField) . ' = ?', $id]); |
| 192 |
|
if (null == $m->$idField) { |
| 193 |
|
$this->failure('authentication_error', "Object with @id does not exist.", 404); |
| 194 |
|
return $this->setOAuthError('invalid_request'); |
| 195 |
|
} |
| 196 |
|
|
| 197 |
|
$this->mapper =& $m; |
| 198 |
|
return $m; |