@@ -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 | } |
@@ -36,7 +36,7 @@ discard block |
||
| 36 | 36 | /** |
| 37 | 37 | * Create a new send issue email notification handler. |
| 38 | 38 | * |
| 39 | - * @param \Illuminate\Contracts\Mail\Mailer $mailer |
|
| 39 | + * @param MailQueue $mailer |
|
| 40 | 40 | * @param \Gitamin\Models\Subscriber $subscriber |
| 41 | 41 | * |
| 42 | 42 | * @return void |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | /** |
| 51 | 51 | * Handle the event. |
| 52 | 52 | * |
| 53 | - * @param \Gitamin\Events\Issue\IssueHasAddedEvent $event |
|
| 53 | + * @param IssueWasAddedEvent $event |
|
| 54 | 54 | * |
| 55 | 55 | * @return void |
| 56 | 56 | */ |
@@ -77,11 +77,11 @@ |
||
| 77 | 77 | 'token' => $subscriber->token, |
| 78 | 78 | 'unsubscribe_link' => route('subscribe.unsubscribe', ['code' => $subscriber->verify_code]), |
| 79 | 79 | ]; |
| 80 | - error_log(var_export($mail,true), 3, '/tmp/mail.log'); |
|
| 80 | + error_log(var_export($mail, true), 3, '/tmp/mail.log'); |
|
| 81 | 81 | $this->mailer->queue([ |
| 82 | 82 | 'html' => 'emails.issues.new-html', |
| 83 | 83 | 'text' => 'emails.issues.new-text', |
| 84 | - ], $mail, function (Message $message) use ($mail) { |
|
| 84 | + ], $mail, function(Message $message) use ($mail) { |
|
| 85 | 85 | $message->to($mail['email'])->subject($mail['subject']); |
| 86 | 86 | }); |
| 87 | 87 | } |
@@ -13,11 +13,7 @@ |
||
| 13 | 13 | |
| 14 | 14 | use Illuminate\Foundation\Bus\DispatchesJobs; |
| 15 | 15 | use Gitamin\Events\Project\ProjectEventInterface; |
| 16 | -use Gitamin\Events\Project\ProjectWasAddedEvent; |
|
| 17 | -use Gitamin\Events\Project\ProjectWasUpdatedEvent; |
|
| 18 | 16 | use Gitamin\Events\Project\ProjectWasRemovedEvent; |
| 19 | -use Gitamin\Handlers\Commands\Moment\AddMomentCommandHandler; |
|
| 20 | -use Gitamin\Commands\Moment\AddMomentCommand; |
|
| 21 | 17 | use Gitamin\Models\Project; |
| 22 | 18 | use Gitamin\Models\Moment; |
| 23 | 19 | |
@@ -48,7 +48,7 @@ |
||
| 48 | 48 | * @param \Gitamin\Models\Project $project |
| 49 | 49 | * @param int $action |
| 50 | 50 | * |
| 51 | - */ |
|
| 51 | + */ |
|
| 52 | 52 | protected function trigger(Project &$project, $action) |
| 53 | 53 | { |
| 54 | 54 | $data = [ |
@@ -31,7 +31,7 @@ discard block |
||
| 31 | 31 | */ |
| 32 | 32 | public function handle(ProjectEventInterface $event) |
| 33 | 33 | { |
| 34 | - if($event instanceof ProjectWasUpdateEvent) { |
|
| 34 | + if ($event instanceof ProjectWasUpdateEvent) { |
|
| 35 | 35 | $action = Moment::UPDATED; |
| 36 | 36 | } else if ($event instanceof ProjectWasRemovedEvent) { |
| 37 | 37 | $action = Moment::CLOSED; |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | * @param int $action |
| 50 | 50 | * |
| 51 | 51 | */ |
| 52 | - protected function trigger(Project &$project, $action) |
|
| 52 | + protected function trigger(Project & $project, $action) |
|
| 53 | 53 | { |
| 54 | 54 | $data = [ |
| 55 | 55 | 'target_type' => 'Project', |
@@ -13,7 +13,6 @@ |
||
| 13 | 13 | |
| 14 | 14 | use Gitamin\Commands\Issue\AddIssueCommand; |
| 15 | 15 | use Gitamin\Http\Controllers\Controller; |
| 16 | -use Gitamin\Models\Issue; |
|
| 17 | 16 | use Gitamin\Models\Project; |
| 18 | 17 | use GrahamCampbell\Binput\Facades\Binput; |
| 19 | 18 | use Illuminate\Support\Facades\Auth; |
@@ -51,10 +51,10 @@ |
||
| 51 | 51 | 'author_id' => $command->author_id, |
| 52 | 52 | ]; |
| 53 | 53 | |
| 54 | - if($command->title) { |
|
| 54 | + if ($command->title) { |
|
| 55 | 55 | $data['title'] = $command->title; |
| 56 | 56 | } |
| 57 | - if($command->data) { |
|
| 57 | + if ($command->data) { |
|
| 58 | 58 | $data['data'] = $command->data; |
| 59 | 59 | } |
| 60 | 60 | // Link with the target. |
@@ -41,11 +41,11 @@ |
||
| 41 | 41 | */ |
| 42 | 42 | public $target_id; |
| 43 | 43 | |
| 44 | - /** |
|
| 45 | - * The moment action. |
|
| 46 | - * |
|
| 47 | - * @var int |
|
| 48 | - */ |
|
| 44 | + /** |
|
| 45 | + * The moment action. |
|
| 46 | + * |
|
| 47 | + * @var int |
|
| 48 | + */ |
|
| 49 | 49 | public $action; |
| 50 | 50 | |
| 51 | 51 | /** |