Completed
Pull Request — master (#70)
by guillaume
06:40
created
app/Src/UseCases/Domain/System/SetInteractionToRegisteredUser.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,10 +23,10 @@
 block discarded – undo
23 23
         $this->authGateway = $authGateway;
24 24
     }
25 25
 
26
-    public function execute():?string
26
+    public function execute(): ?string
27 27
     {
28 28
         $currentUser = $this->authGateway->current();
29
-        if(!isset($currentUser)){
29
+        if (!isset($currentUser)) {
30 30
             return 'nothing_to_do';
31 31
         }
32 32
         $anonymousUser = new AnonymousUser($this->authGateway->wikiSessionId());
Please login to merge, or discard this patch.
app/Src/UseCases/Domain/Shared/Gateway/AuthGateway.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@
 block discarded – undo
8 8
 
9 9
 interface AuthGateway
10 10
 {
11
-    public function current():? User;
11
+    public function current(): ? User;
12 12
     public function log(User $u);
13 13
     public function wikiSessionId():string;
14 14
 }
Please login to merge, or discard this patch.
app/Src/UseCases/Domain/Ports/PageRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,6 +8,6 @@
 block discarded – undo
8 8
 
9 9
 interface PageRepository
10 10
 {
11
-    public function get(string $pageId):?Page;
11
+    public function get(string $pageId): ?Page;
12 12
     public function save(Page $page);
13 13
 }
Please login to merge, or discard this patch.
app/Src/UseCases/Domain/Ports/InteractionRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,5 +10,5 @@
 block discarded – undo
10 10
 interface InteractionRepository
11 11
 {
12 12
     public function save(CanInteract $canInteract, Interaction $interaction);
13
-    public function getByInteractUser(CanInteract $canInteract, int $pageId):?Interaction;
13
+    public function getByInteractUser(CanInteract $canInteract, int $pageId): ?Interaction;
14 14
 }
Please login to merge, or discard this patch.
app/Src/UseCases/Domain/Users/Interactions/HandleInteractions.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@
 block discarded – undo
48 48
 
49 49
         $canInteractUser = $this->getInteractUser();
50 50
         $interaction = $this->interactionRepository->getByInteractUser($canInteractUser, $pageId);
51
-        if(!isset($interaction)) {
51
+        if (!isset($interaction)) {
52 52
             $canInteractUser->addInteraction($interactions, $pageId, $doneValue);
53 53
             return;
54 54
         }
Please login to merge, or discard this patch.
app/Src/UseCases/Domain/Agricultural/Model/Interaction.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,8 +33,8 @@
 block discarded – undo
33 33
 
34 34
     public function update(array $interactions, array $doneValue = [])
35 35
     {
36
-        foreach ($interactions as $interaction){
37
-            switch ($interaction){
36
+        foreach ($interactions as $interaction) {
37
+            switch ($interaction) {
38 38
                 case 'follow':
39 39
                     $this->follow = true;
40 40
                     break;
Please login to merge, or discard this patch.