Renamed some methods.

This commit is contained in:
James Cole
2015-03-29 08:24:56 +02:00
parent 4c8bc49a7e
commit a7501c396f
3 changed files with 19 additions and 19 deletions

View File

@@ -32,7 +32,7 @@ class HelpController extends Controller
return Response::json($content);
}
if ($this->_inCache($route)) {
if ($this->inCache($route)) {
$content = [
'text' => Cache::get('help.' . $route . '.text'),
'title' => Cache::get('help.' . $route . '.title'),
@@ -40,7 +40,7 @@ class HelpController extends Controller
return Response::json($content);
}
$content = $this->_getFromGithub($route);
$content = $this->getFromGithub($route);
Cache::put('help.' . $route . '.text', $content['text'], 10080); // a week.
@@ -55,7 +55,7 @@ class HelpController extends Controller
*
* @return bool
*/
protected function _inCache($route)
protected function inCache($route)
{
return Cache::has('help.' . $route . '.title') && Cache::has('help.' . $route . '.text');
}
@@ -65,7 +65,7 @@ class HelpController extends Controller
*
* @return array
*/
protected function _getFromGithub($route)
protected function getFromGithub($route)
{
$uri = 'https://raw.githubusercontent.com/JC5/firefly-iii-help/master/' . e($route) . '.md';
$content = [