Passed
Push — main ( 6d7bd8...b9bb24 )
by Slawomir
04:03
created
src/Modules/Comments/Domain/Logic/CommentsCreator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,10 +42,10 @@
 block discarded – undo
42 42
         $this->validator->preCreate($command);
43 43
         $newComment = $this->fromCreateCommand($command);
44 44
         $id = $this->transactionFactory
45
-            ->createTransaction(function () use ($newComment) {
45
+            ->createTransaction(function() use ($newComment) {
46 46
                 return $this->commentsCreationRepository->createComment($newComment);
47 47
             })
48
-            ->afterCommit(function ($id) use ($newComment, $command) {
48
+            ->afterCommit(function($id) use ($newComment, $command) {
49 49
                 $this->eventPublisher->publish(new CommentCreatedOEvent($command->getPostId(),
50 50
                         new CommentDto($id,
51 51
                             $newComment->getAuthor(),
Please login to merge, or discard this patch.
src/Modules/Comments/Api/Command/BaselineCommentsCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
 
42 42
         $from = $input->getArgument("from");
43 43
         if ($from != null) {
44
-            $this->from = \DateTime::createFromFormat("Y-m-d H:i:s", $from . "00:00:00");
44
+            $this->from = \DateTime::createFromFormat("Y-m-d H:i:s", $from."00:00:00");
45 45
         }
46 46
         $this->commentsApi->baseline($this);
47 47
         if ($from != null) {
Please login to merge, or discard this patch.
src/Infrastructure/Services/ParamConverter/JsonParamConverter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@
 block discarded – undo
77 77
         $errors = $this->validator->validate($object);
78 78
         if (count($errors) > 0) {
79 79
             throw new BadRequestException(sprintf('Invalid Request Body: %s',
80
-                (string)$errors));
80
+                (string) $errors));
81 81
         }
82 82
         return $object;
83 83
     }
Please login to merge, or discard this patch.
src/Infrastructure/Events/ApplicationInboundEvent.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -104,7 +104,7 @@
 block discarded – undo
104 104
         if ($value == null) {
105 105
             return null;
106 106
         }
107
-        return is_string($value) ? $value : (string)$value;
107
+        return is_string($value) ? $value : (string) $value;
108 108
     }
109 109
 
110 110
     /**
Please login to merge, or discard this patch.
src/Infrastructure/Security/JWTLoggedInUserProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,6 +25,6 @@
 block discarded – undo
25 25
         if ($user instanceof LoggedInUser) {
26 26
             return $user;
27 27
         }
28
-        throw new \RuntimeException("Unsupported User Class: " . $user::class);
28
+        throw new \RuntimeException("Unsupported User Class: ".$user::class);
29 29
     }
30 30
 }
31 31
\ No newline at end of file
Please login to merge, or discard this patch.
src/Modules/Comments/Domain/Logic/PostHeadersFinder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
     public function findPostHeaders(): array
24 24
     {
25 25
         return Collection::from($this->headersFindingRepository->findPostHeaders())
26
-            ->map(function ($header) {
26
+            ->map(function($header) {
27 27
                 return new FindCommentsPostHeadersQueryResponse(
28 28
                     $header->getId(),
29 29
                     $header->getTitle(),
Please login to merge, or discard this patch.
src/Modules/Security/Domain/Logic/CommentsEventsHandler.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
    public function onCommentsCountUpdated(CommentsCountUpdatedSecurityIEvent $event): void
28 28
     {
29 29
         $this->transactionFactory
30
-            ->createTransaction(function () use ($event) {
30
+            ->createTransaction(function() use ($event) {
31 31
                 $this->commentsEventHandlingRepository->updatePostCommentsCount(
32 32
                     new UpdatePostsCommentsCountDto($event->getPostId(), $event->getCommentsCount())
33 33
                 );
Please login to merge, or discard this patch.
src/Modules/Security/Domain/Logic/PostHeadersFinder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     public function findPostHeaders(): array
28 28
     {
29 29
         return Collection::from($this->headersFindingRepository->findPostHeaders())
30
-            ->map(function ($header) {
30
+            ->map(function($header) {
31 31
                 return new FindUserPostHeadersQueryResponse(
32 32
                     $header->getId(),
33 33
                     $header->getTitle(),
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
     {
51 51
         $page = $this->headersFindingRepository->findPostsByUserId($query->getUserId(), $query->getPageNo());
52 52
         $data = Collection::from($page->getData())
53
-            ->map(function ($header) {
53
+            ->map(function($header) {
54 54
                 return new FindPostsByUserIdQueryResponse(
55 55
                     $header->getId(),
56 56
                     $header->getTitle(),
Please login to merge, or discard this patch.
src/Modules/Tags/Domain/Logic/CommentsEventsHandler.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
    public function onCommentsCountUpdated(CommentsCountUpdatedTagsIEvent $event): void
28 28
     {
29 29
         $this->transactionFactory
30
-            ->createTransaction(function () use ($event) {
30
+            ->createTransaction(function() use ($event) {
31 31
                 $this->commentsEventHandlingRepository->updatePostCommentsCount(
32 32
                     new UpdatePostsCommentsCountDto($event->getPostId(), $event->getCommentsCount())
33 33
                 );
Please login to merge, or discard this patch.