Make these functions public to prevent scrutinizer from complaining.

This commit is contained in:
jgen
2014-04-26 00:27:16 -04:00
parent e6b1d514d1
commit 298344048c
5 changed files with 25 additions and 20 deletions

View File

@ -573,12 +573,17 @@ class OuroborosAPI extends Extension
protected function postShow($id = null)
{
if (!is_null($id)) {
$post = new _SafeOuroborosImage(Image::by_id($id));
$this->sendData('post', $post);
} else {
$this->sendResponse(424, 'ID is mandatory');
}
}
$image = Image::by_id($id);
if ( ! $image instanceof Image) {
$this->sendResponse(404, 'ID not found');
} else {
$post = new _SafeOuroborosImage($image);
$this->sendData('post', $post);
}
} else {
$this->sendResponse(424, 'ID is mandatory');
}
}
/**
* Wrapper for getting a list of posts