@@ -78,7 +78,6 @@ |
||
| 78 | 78 | * @param string $path |
| 79 | 79 | * @param int $creator_id |
| 80 | 80 | * @param int $owner_id |
| 81 | - * @param bool $issues_enabled |
|
| 82 | 81 | * |
| 83 | 82 | * @return void |
| 84 | 83 | */ |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | * |
| 31 | 31 | * @param \Symfony\Component\HttpFoundation\Request $request |
| 32 | 32 | * |
| 33 | - * @return \Illuminate\Http\JsonResponse |
|
| 33 | + * @return \Illuminate\Http\Response |
|
| 34 | 34 | */ |
| 35 | 35 | public function getTeams(Request $request) |
| 36 | 36 | { |
@@ -44,7 +44,7 @@ discard block |
||
| 44 | 44 | * |
| 45 | 45 | * @param \Gitamin\Models\ProjectTeam $team |
| 46 | 46 | * |
| 47 | - * @return \Illuminate\Http\JsonResponse |
|
| 47 | + * @return \Illuminate\Http\Response |
|
| 48 | 48 | */ |
| 49 | 49 | public function getTeam(ProjectTeam $team) |
| 50 | 50 | { |
@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | /** |
| 55 | 55 | * Create a new project team. |
| 56 | 56 | * |
| 57 | - * @return \Illuminate\Http\JsonResponse |
|
| 57 | + * @return \Illuminate\Http\Response |
|
| 58 | 58 | */ |
| 59 | 59 | public function postTeams() |
| 60 | 60 | { |
@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | * |
| 77 | 77 | * @param \Gitamin\Models\ProjectTeam $team |
| 78 | 78 | * |
| 79 | - * @return \Illuminate\Http\JsonResponse |
|
| 79 | + * @return \Illuminate\Http\Response |
|
| 80 | 80 | */ |
| 81 | 81 | public function putTeam(ProjectTeam $team) |
| 82 | 82 | { |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | * |
| 100 | 100 | * @param \Gitamin\Models\ProjectTeam $team |
| 101 | 101 | * |
| 102 | - * @return \Illuminate\Http\JsonResponse |
|
| 102 | + * @return \Illuminate\Http\Response |
|
| 103 | 103 | */ |
| 104 | 104 | public function deleteTeam(ProjectTeam $team) |
| 105 | 105 | { |
@@ -71,7 +71,7 @@ |
||
| 71 | 71 | /** |
| 72 | 72 | * Generates a feed of all issues. |
| 73 | 73 | * |
| 74 | - * @param \Gitamin\Models\Owner|null $owner |
|
| 74 | + * @param Owner $owner |
|
| 75 | 75 | * @param bool $isRss |
| 76 | 76 | * |
| 77 | 77 | * @return \Illuminate\Http\Response |
@@ -76,16 +76,16 @@ |
||
| 76 | 76 | * |
| 77 | 77 | * @return \Illuminate\Http\Response |
| 78 | 78 | */ |
| 79 | - private function feedAction(Owner &$owner, $isRss) |
|
| 79 | + private function feedAction(Owner & $owner, $isRss) |
|
| 80 | 80 | { |
| 81 | 81 | if ($owner->exists) { |
| 82 | - $owner->projects->map(function ($project) { |
|
| 83 | - $project->issues()->visible()->orderBy('created_at', 'desc')->get()->map(function ($issue) use ($isRss) { |
|
| 82 | + $owner->projects->map(function($project) { |
|
| 83 | + $project->issues()->visible()->orderBy('created_at', 'desc')->get()->map(function($issue) use ($isRss) { |
|
| 84 | 84 | $this->feedAddItem($issue, $isRss); |
| 85 | 85 | }); |
| 86 | 86 | }); |
| 87 | 87 | } else { |
| 88 | - Issue::visible()->orderBy('created_at', 'desc')->get()->map(function ($issue) use ($isRss) { |
|
| 88 | + Issue::visible()->orderBy('created_at', 'desc')->get()->map(function($issue) use ($isRss) { |
|
| 89 | 89 | $this->feedAddItem($issue, $isRss); |
| 90 | 90 | }); |
| 91 | 91 | } |
@@ -30,7 +30,7 @@ |
||
| 30 | 30 | event(new OwnerWasRemovedEvent($owner)); |
| 31 | 31 | |
| 32 | 32 | // Remove the owner id from all project. |
| 33 | - $owner->projects->map(function ($project) { |
|
| 33 | + $owner->projects->map(function($project) { |
|
| 34 | 34 | $project->update(['owner_id' => 0]); |
| 35 | 35 | }); |
| 36 | 36 | |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | */ |
| 162 | 162 | public static function findByPath($owner_path, $project_path, $columns = ['projects.*']) |
| 163 | 163 | { |
| 164 | - $project = static::leftJoin('owners', function ($join) { |
|
| 164 | + $project = static::leftJoin('owners', function($join) { |
|
| 165 | 165 | $join->on('projects.owner_id', '=', 'owners.id'); |
| 166 | 166 | })->where('projects.path', '=', $project_path)->where('owners.path', '=', $owner_path)->first($columns); |
| 167 | 167 | |
@@ -215,7 +215,7 @@ discard block |
||
| 215 | 215 | */ |
| 216 | 216 | public function getTagsListAttribute() |
| 217 | 217 | { |
| 218 | - $tags = $this->tags->map(function ($tag) { |
|
| 218 | + $tags = $this->tags->map(function($tag) { |
|
| 219 | 219 | return $tag->name; |
| 220 | 220 | }); |
| 221 | 221 | |
@@ -12,7 +12,6 @@ |
||
| 12 | 12 | namespace Gitamin\Http\Controllers; |
| 13 | 13 | |
| 14 | 14 | use Gitamin\Facades\Setting; |
| 15 | -use Gitamin\Models\Project; |
|
| 16 | 15 | use Gitter\Client; |
| 17 | 16 | use Illuminate\Routing\Controller; |
| 18 | 17 | use Illuminate\Support\Facades\View; |
@@ -11,7 +11,6 @@ |
||
| 11 | 11 | |
| 12 | 12 | namespace Gitamin\Presenters; |
| 13 | 13 | |
| 14 | -use Gitamin\Facades\Setting; |
|
| 15 | 14 | use Gitamin\Presenters\Traits\TimestampsTrait; |
| 16 | 15 | use GrahamCampbell\Markdown\Facades\Markdown; |
| 17 | 16 | use Jenssegers\Date\Date; |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | * @param \Symfony\Component\HttpFoundation\Request $request |
| 33 | 33 | * @param \Illuminate\Contracts\Auth\Guard $auth |
| 34 | 34 | * |
| 35 | - * @return \Illuminate\Http\JsonResponse |
|
| 35 | + * @return \Illuminate\Http\Response |
|
| 36 | 36 | */ |
| 37 | 37 | public function getComments(Request $request, Guard $auth) |
| 38 | 38 | { |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | * |
| 47 | 47 | * @param \Gitamin\Models\Comment $comment |
| 48 | 48 | * |
| 49 | - * @return \Illuminate\Http\JsonResponse |
|
| 49 | + * @return \Illuminate\Http\Response |
|
| 50 | 50 | */ |
| 51 | 51 | public function getComment(Comment $comment) |
| 52 | 52 | { |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | * |
| 59 | 59 | * @param \Illuminate\Contracts\Auth\Guard $auth |
| 60 | 60 | * |
| 61 | - * @return \Illuminate\Http\JsonResponse |
|
| 61 | + * @return \Illuminate\Http\Response |
|
| 62 | 62 | */ |
| 63 | 63 | public function postComments(Guard $auth) |
| 64 | 64 | { |
@@ -80,9 +80,9 @@ discard block |
||
| 80 | 80 | /** |
| 81 | 81 | * Update an existing comment. |
| 82 | 82 | * |
| 83 | - * @param \Gitamin\Models\Inicdent $comment |
|
| 83 | + * @param Comment $comment |
|
| 84 | 84 | * |
| 85 | - * @return \Illuminate\Http\JsonResponse |
|
| 85 | + * @return \Illuminate\Http\Response |
|
| 86 | 86 | */ |
| 87 | 87 | public function putComment(Comment $comment) |
| 88 | 88 | { |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | * |
| 104 | 104 | * @param \Gitamin\Models\Comment $comment |
| 105 | 105 | * |
| 106 | - * @return \Illuminate\Http\JsonResponse |
|
| 106 | + * @return \Illuminate\Http\Response |
|
| 107 | 107 | */ |
| 108 | 108 | public function deleteComment(Comment $comment) |
| 109 | 109 | { |
@@ -54,7 +54,7 @@ |
||
| 54 | 54 | 'team_id' => $command->team_id, |
| 55 | 55 | ]; |
| 56 | 56 | |
| 57 | - return array_filter($params, function ($val) { |
|
| 57 | + return array_filter($params, function($val) { |
|
| 58 | 58 | return $val !== null; |
| 59 | 59 | }); |
| 60 | 60 | } |