Permalink
Browse files

加上 PHPDoc

  • Loading branch information...
1 parent 4c015e7 commit 51b7adc049927b19bd87f25bf26116932b61abff @oomusou committed Jul 24, 2016
Showing with 1 addition and 17 deletions.
  1. +1 −17 app/Services/PostService.php
@@ -27,24 +27,8 @@ public function __construct(PostRepository $postRepository)
*/
public function showTitle(int $id, string $default) : string
{
- switch ($id) {
- case 1 :
-
-
-
- $defaultTitle = 'No title 1';
-
- case 2 :
- $defaultTitle = 'No title 2';
- break;
-
- default:
- $defaultTitle = $default;
- break;
- }
-
return $this->postRepository
- ->getTitle($id, $defaultTitle)
+ ->getTitle($id, $default)
->title;
}
}

0 comments on commit 51b7adc

Please sign in to comment.