Completed
Push — develop ( bffb2a...35cb48 )
by
unknown
07:30
created
module/Auth/src/Auth/Adapter/HybridAuth.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -211,14 +211,14 @@
 block discarded – undo
211 211
     {
212 212
         return $this->repository;
213 213
     }
214
-	/**
215
-	 * @param SocialProfilePlugin
216
-	 * @return HybridAuth
217
-	 */
218
-	public function setSocialProfilePlugin(SocialProfilePlugin $socialProfilePlugin)
219
-	{
220
-		$this->socialProfilePlugin = $socialProfilePlugin;
214
+    /**
215
+     * @param SocialProfilePlugin
216
+     * @return HybridAuth
217
+     */
218
+    public function setSocialProfilePlugin(SocialProfilePlugin $socialProfilePlugin)
219
+    {
220
+        $this->socialProfilePlugin = $socialProfilePlugin;
221 221
 		
222
-		return $this;
223
-	}
222
+        return $this;
223
+    }
224 224
 }
Please login to merge, or discard this patch.
module/Auth/src/Auth/Form/SocialProfiles.php 2 patches
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -61,14 +61,14 @@
 block discarded – undo
61 61
         return $this->useDefaultValidation ? \Zend\Form\Form::isValid() : parent::isValid();
62 62
     }
63 63
     
64
-	/**
65
-	 * @param bool $bool
66
-	 * @return SocialProfiles
67
-	 */
68
-	public function setUseDefaultValidation($bool)
69
-	{
70
-		$this->useDefaultValidation = (bool)$bool;
64
+    /**
65
+     * @param bool $bool
66
+     * @return SocialProfiles
67
+     */
68
+    public function setUseDefaultValidation($bool)
69
+    {
70
+        $this->useDefaultValidation = (bool)$bool;
71 71
 		
72
-		return $this;
73
-	}
72
+        return $this;
73
+    }
74 74
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
 	 */
68 68
 	public function setUseDefaultValidation($bool)
69 69
 	{
70
-		$this->useDefaultValidation = (bool)$bool;
70
+		$this->useDefaultValidation = (bool) $bool;
71 71
 		
72 72
 		return $this;
73 73
 	}
Please login to merge, or discard this patch.
module/Auth/src/Auth/Controller/ManageController.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
             }, $userProfiles)]);
54 54
         
55 55
         $translator = $serviceLocator->get('Translator');
56
-		$formSocialProfiles->getBaseFieldset()
56
+        $formSocialProfiles->getBaseFieldset()
57 57
             ->setOption('description', $translator->translate("you can add your social profile to your application. You can preview and remove the attached profile before submitting the application."));
58 58
         $container->setEntity($user);
59 59
 
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -43,11 +43,11 @@  discard block
 block discarded – undo
43 43
         $forms = $serviceLocator->get('forms');
44 44
         $container = $forms->get('Auth/userprofilecontainer');
45 45
         $user = $serviceLocator->get('AuthenticationService')->getUser(); /* @var $user \Auth\Entity\User */
46
-        $postProfiles = (array)$this->params()->fromPost('social_profiles');
46
+        $postProfiles = (array) $this->params()->fromPost('social_profiles');
47 47
         $userProfiles = $user->getProfile();
48 48
         $formSocialProfiles = $forms->get('Auth/SocialProfiles')
49 49
             ->setUseDefaultValidation(true)
50
-            ->setData(['social_profiles' => array_map(function ($array)
50
+            ->setData(['social_profiles' => array_map(function($array)
51 51
             {
52 52
                 return $array['data'];
53 53
             }, $userProfiles)]);
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
                                 ));
127 127
                             } else {
128 128
                                 $profile = [
129
-                                    'auth' => (array)$authProfile,
129
+                                    'auth' => (array) $authProfile,
130 130
                                     'data' => \Zend\Json\Json::decode($dataProfiles[$network])
131 131
                                 ];
132 132
                                 $user->addProfile($network, $profile);
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
                 }
137 137
                 
138 138
                 // keep data in sync & properly decoded
139
-                $formSocialProfiles->setData(['social_profiles' => array_map(function ($array)
139
+                $formSocialProfiles->setData(['social_profiles' => array_map(function($array)
140 140
                 {
141 141
                     return \Zend\Json\Json::decode($array) ?: '';
142 142
                 }, $dataProfiles)]);
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -96,8 +96,7 @@
 block discarded – undo
96 96
                     'content' => $content,
97 97
                     )
98 98
                 );
99
-            }
100
-            elseif ($postProfiles) {
99
+            } elseif ($postProfiles) {
101 100
                 $formSocialProfiles->setData($this->params()->fromPost());
102 101
                 
103 102
                 if ($formSocialProfiles->isValid()) {
Please login to merge, or discard this patch.
module/Auth/src/Auth/Repository/User.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
      */
88 88
     public function findByProfileIdentifier($identifier, $provider)
89 89
     {
90
-        return $this->findOneBy(array('profiles.' . $provider . '.auth.identifier' => $identifier)) ?: $this->findOneBy(array('profile.identifier' => $identifier));
90
+        return $this->findOneBy(array('profiles.'.$provider.'.auth.identifier' => $identifier)) ?: $this->findOneBy(array('profile.identifier' => $identifier));
91 91
     }
92 92
     
93 93
     /**
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
         $qb->field('_id')->notEqual($curentUserId)
105 105
             ->addAnd(
106 106
                 $qb->expr()
107
-                    ->addOr($qb->expr()->field('profiles.' . $provider . '.auth.identifier' )->equals($identifier))
107
+                    ->addOr($qb->expr()->field('profiles.'.$provider.'.auth.identifier')->equals($identifier))
108 108
                     ->addOr($qb->expr()->field('profile.identifier')->equals($identifier))
109 109
             );
110 110
         
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
         return $this->findOneBy(
160 160
             array(
161 161
             '$or' => array(
162
-                array('login' => $identity . $suffix),
162
+                array('login' => $identity.$suffix),
163 163
                 array('info.email' => $identity)
164 164
             )
165 165
             )
@@ -208,10 +208,10 @@  discard block
 block discarded – undo
208 208
     public function findByQuery($query)
209 209
     {
210 210
         $qb = $this->createQueryBuilder();
211
-        $parts  = explode(' ', trim($query));
211
+        $parts = explode(' ', trim($query));
212 212
         
213 213
         foreach ($parts as $q) {
214
-            $regex = new \MongoRegex('/^' . $query . '/i');
214
+            $regex = new \MongoRegex('/^'.$query.'/i');
215 215
             $qb->addOr($qb->expr()->field('info.firstName')->equals($regex));
216 216
             $qb->addOr($qb->expr()->field('info.lastName')->equals($regex));
217 217
             $qb->addOr($qb->expr()->field('info.email')->equals($regex));
Please login to merge, or discard this patch.