@@ 88-91 (lines=4) @@ | ||
85 | // Build the request path. |
|
86 | $path = "/orgs/$org/hooks"; |
|
87 | ||
88 | if (false == in_array($contentType, array('form', 'json'))) |
|
89 | { |
|
90 | throw new \UnexpectedValueException('Content type must be either "form" or "json".'); |
|
91 | } |
|
92 | ||
93 | $config = array( |
|
94 | 'url' => $url, |
|
@@ 160-163 (lines=4) @@ | ||
157 | ||
158 | if ($contentType) |
|
159 | { |
|
160 | if (false == in_array($contentType, array('form', 'json'))) |
|
161 | { |
|
162 | throw new \UnexpectedValueException('Content type must be either "form" or "json".'); |
|
163 | } |
|
164 | ||
165 | $config['content_type'] = $contentType; |
|
166 | } |