Test Setup Failed
Branch master (33ce72)
by masoud
10:58
created
src/Auth/SessionHandler.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,8 +36,9 @@
 block discarded – undo
36 36
     }
37 37
     public static function validateCredentials(VmwareApiClient $client)
38 38
     {
39
-        if((array_key_exists("username",$client->credential) && array_key_exists("password",$client->credential)) or array_key_exists("Vmware-Api-Session-Id",$client->credential))
40
-            return true;
39
+        if((array_key_exists("username",$client->credential) && array_key_exists("password",$client->credential)) or array_key_exists("Vmware-Api-Session-Id",$client->credential)) {
40
+                    return true;
41
+        }
41 42
         throw new CredentialException("required parameter you should send session-id or username-password for auth api ");
42 43
     }
43 44
     public static function convertCredentials($credentials){
Please login to merge, or discard this patch.
src/Api/VM/Traits/MOID.php 1 patch
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -7,10 +7,12 @@
 block discarded – undo
7 7
 trait MOID
8 8
 {
9 9
     public function getMoid($moid=null){
10
-        if($moid)
11
-            return $moid;
12
-        if($this->vmSource && isset($this->vmSource->moid))
13
-            return $this->vmSource->moid;
10
+        if($moid) {
11
+                    return $moid;
12
+        }
13
+        if($this->vmSource && isset($this->vmSource->moid)) {
14
+                    return $this->vmSource->moid;
15
+        }
14 16
         throw new \InvalidArgumentException("provide moid or pass vmSource object");
15 17
     }
16 18
 }
17 19
\ No newline at end of file
Please login to merge, or discard this patch.