@@ -56,7 +56,9 @@ |
||
| 56 | 56 | try { |
| 57 | 57 | $response = $this->getFromLearningLocker($this->url($this->id ?? $this->id)); |
| 58 | 58 | |
| 59 | - if ($selected) $response = $this->select($selected, $response); |
|
| 59 | + if ($selected) { |
|
| 60 | + $response = $this->select($selected, $response); |
|
| 61 | + } |
|
| 60 | 62 | |
| 61 | 63 | return $response; |
| 62 | 64 | } catch (Exception $e) { |
@@ -55,7 +55,9 @@ |
||
| 55 | 55 | try { |
| 56 | 56 | $response = $this->getFromLearningLocker($this->url($this->id ?? $this->id)); |
| 57 | 57 | |
| 58 | - if ($selected) $response = $this->select($selected, $response); |
|
| 58 | + if ($selected) { |
|
| 59 | + $response = $this->select($selected, $response); |
|
| 60 | + } |
|
| 59 | 61 | |
| 60 | 62 | return $response; |
| 61 | 63 | } catch (Exception $e) { |
@@ -55,7 +55,9 @@ |
||
| 55 | 55 | try { |
| 56 | 56 | $response = $this->getFromLearningLocker($this->url($this->id ?? $this->id)); |
| 57 | 57 | |
| 58 | - if ($selected) $response = $this->select($selected, $response); |
|
| 58 | + if ($selected) { |
|
| 59 | + $response = $this->select($selected, $response); |
|
| 60 | + } |
|
| 59 | 61 | |
| 60 | 62 | return $response; |
| 61 | 63 | } catch (Exception $e) { |
@@ -46,7 +46,9 @@ discard block |
||
| 46 | 46 | public function forwarding(string $id = null) |
| 47 | 47 | { |
| 48 | 48 | $statement_forwarding = new ForwardingHandler($id ? $id : null, $this->key, $this->secret, $this->url); |
| 49 | - if ($statement_forwarding) return $statement_forwarding; |
|
| 49 | + if ($statement_forwarding) { |
|
| 50 | + return $statement_forwarding; |
|
| 51 | + } |
|
| 50 | 52 | |
| 51 | 53 | return self::statementForwarding($id ? $id : null); |
| 52 | 54 | } |
@@ -71,7 +73,9 @@ discard block |
||
| 71 | 73 | try { |
| 72 | 74 | $response = $this->getFromLearningLocker($this->url($this->id ?? $this->id)); |
| 73 | 75 | |
| 74 | - if ($selected) $response = $this->select($selected, $response); |
|
| 76 | + if ($selected) { |
|
| 77 | + $response = $this->select($selected, $response); |
|
| 78 | + } |
|
| 75 | 79 | |
| 76 | 80 | return $response; |
| 77 | 81 | } catch (Exception $e) { |
@@ -59,7 +59,9 @@ discard block |
||
| 59 | 59 | self::HEADERS => $this->headers() |
| 60 | 60 | ]); |
| 61 | 61 | |
| 62 | - if ( $response->getStatusCode() === 404 ) return null; |
|
| 62 | + if ( $response->getStatusCode() === 404 ) { |
|
| 63 | + return null; |
|
| 64 | + } |
|
| 63 | 65 | |
| 64 | 66 | return $this->response($response); |
| 65 | 67 | } catch (ClientException $e) { |
@@ -76,7 +78,9 @@ discard block |
||
| 76 | 78 | self::BODY => $this->data($data) |
| 77 | 79 | ]); |
| 78 | 80 | |
| 79 | - if ( $response->getStatusCode() === 404 ) return null; |
|
| 81 | + if ( $response->getStatusCode() === 404 ) { |
|
| 82 | + return null; |
|
| 83 | + } |
|
| 80 | 84 | |
| 81 | 85 | return $this->response($response); |
| 82 | 86 | } catch (ClientException $e) { |
@@ -92,7 +96,9 @@ discard block |
||
| 92 | 96 | self::HEADERS => $this->headers() |
| 93 | 97 | ]); |
| 94 | 98 | |
| 95 | - if ($response->getStatusCode() === 404) return null; |
|
| 99 | + if ($response->getStatusCode() === 404) { |
|
| 100 | + return null; |
|
| 101 | + } |
|
| 96 | 102 | |
| 97 | 103 | return $this->response($response); |
| 98 | 104 | } catch (ClientException $e) { |
@@ -55,7 +55,9 @@ |
||
| 55 | 55 | try { |
| 56 | 56 | $response = $this->getFromLearningLocker($this->url($this->id ?? $this->id)); |
| 57 | 57 | |
| 58 | - if ($selected) $response = $this->select($selected, $response); |
|
| 58 | + if ($selected) { |
|
| 59 | + $response = $this->select($selected, $response); |
|
| 60 | + } |
|
| 59 | 61 | |
| 60 | 62 | return $response; |
| 61 | 63 | } catch (Exception $e) { |
@@ -56,7 +56,9 @@ |
||
| 56 | 56 | try { |
| 57 | 57 | $response = $this->getFromLearningLocker($this->url($this->id ?? $this->id)); |
| 58 | 58 | |
| 59 | - if ($selected) $response = $this->select($selected, $response); |
|
| 59 | + if ($selected) { |
|
| 60 | + $response = $this->select($selected, $response); |
|
| 61 | + } |
|
| 60 | 62 | |
| 61 | 63 | return $response; |
| 62 | 64 | } catch (Exception $e) { |
@@ -54,7 +54,9 @@ |
||
| 54 | 54 | public function progress(string $id = null) |
| 55 | 55 | { |
| 56 | 56 | $progress = new ProgressHandler($id ? $id : null, $this->key, $this->secret, $this->url); |
| 57 | - if ($progress) return $progress; |
|
| 57 | + if ($progress) { |
|
| 58 | + return $progress; |
|
| 59 | + } |
|
| 58 | 60 | |
| 59 | 61 | return self::progress($id ? $id : null); |
| 60 | 62 | } |
@@ -43,7 +43,9 @@ discard block |
||
| 43 | 43 | public function identifier(string $id = null) |
| 44 | 44 | { |
| 45 | 45 | $identifier = new IdentifierHandler($id ? $id : null, $this->key, $this->secret, $this->url); |
| 46 | - if ($identifier) return $identifier; |
|
| 46 | + if ($identifier) { |
|
| 47 | + return $identifier; |
|
| 48 | + } |
|
| 47 | 49 | |
| 48 | 50 | return self::identifier($id ? $id : null); |
| 49 | 51 | } |
@@ -57,7 +59,9 @@ discard block |
||
| 57 | 59 | public function attributes(string $id = null) |
| 58 | 60 | { |
| 59 | 61 | $attribute = new AttributeHandler($id ? $id : null, $this->key, $this->secret, $this->url); |
| 60 | - if ($attribute) return $attribute; |
|
| 62 | + if ($attribute) { |
|
| 63 | + return $attribute; |
|
| 64 | + } |
|
| 61 | 65 | |
| 62 | 66 | return self::attribute($id ? $id : null); |
| 63 | 67 | } |
@@ -71,7 +75,9 @@ discard block |
||
| 71 | 75 | public function attribute(string $id = null) |
| 72 | 76 | { |
| 73 | 77 | $attribute = new AttributeHandler($id ? $id : null, $this->key, $this->secret, $this->url); |
| 74 | - if ($attribute) return $attribute; |
|
| 78 | + if ($attribute) { |
|
| 79 | + return $attribute; |
|
| 80 | + } |
|
| 75 | 81 | |
| 76 | 82 | return self::attribute($id ? $id : null); |
| 77 | 83 | } |
@@ -85,7 +91,9 @@ discard block |
||
| 85 | 91 | public function import(string $id = null) |
| 86 | 92 | { |
| 87 | 93 | $import = new ImportHandler($id ? $id : null, $this->key, $this->secret, $this->url); |
| 88 | - if ($import) return $import; |
|
| 94 | + if ($import) { |
|
| 95 | + return $import; |
|
| 96 | + } |
|
| 89 | 97 | |
| 90 | 98 | return self::import($id ? $id : null); |
| 91 | 99 | } |