@@ -133,8 +133,7 @@ |
||
| 133 | 133 | $headers = []; |
| 134 | 134 | if (function_exists('apache_request_headers')) { |
| 135 | 135 | $headers = apache_request_headers(); |
| 136 | - } |
|
| 137 | - else { |
|
| 136 | + } else { |
|
| 138 | 137 | foreach ($_SERVER as $name => $value) { |
| 139 | 138 | if (substr(strtoupper($name), 0, 5) == 'HTTP_') { |
| 140 | 139 | $headers[str_replace(' ', '-', ucwords(strtoupper(str_replace('_', ' ', substr($name, 5)))))] = $value; |
@@ -179,11 +179,9 @@ |
||
| 179 | 179 | { |
| 180 | 180 | if ($server === static::USE_PRODUCTION_SERVER) { |
| 181 | 181 | $url = 'https://api.authorize.net/rest/v1/'; |
| 182 | - } |
|
| 183 | - else if ($server === static::USE_DEVELOPMENT_SERVER) { |
|
| 182 | + } else if ($server === static::USE_DEVELOPMENT_SERVER) { |
|
| 184 | 183 | $url = 'https://apitest.authorize.net/rest/v1/'; |
| 185 | - } |
|
| 186 | - else { |
|
| 184 | + } else { |
|
| 187 | 185 | throw new AuthnetInvalidServerException('You did not provide a valid server.'); |
| 188 | 186 | } |
| 189 | 187 | return $url; |
@@ -70,8 +70,7 @@ |
||
| 70 | 70 | $output .= '<tr><td colspan="2"><pre>' . "\n"; |
| 71 | 71 | $output .= $this->requestJson . "\n"; |
| 72 | 72 | $output .= '</pre></td></tr>' . "\n"; |
| 73 | - } |
|
| 74 | - else { |
|
| 73 | + } else { |
|
| 75 | 74 | $output .= '<tr><td colspan="2" style="text-align: center;"><pre>N/A</pre></td></tr>' . "\n"; |
| 76 | 75 | } |
| 77 | 76 | $output .= '</table>'; |