Skip to content

Commit 346761b

Browse files
committed
Merge pull request #280 from GrahamForks/patch-2
Supported api versions makes no sense
2 parents 8727a7f + 2d57b47 commit 346761b

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

lib/Github/Client.php

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -307,24 +307,10 @@ public function setOption($name, $value)
307307
if (!array_key_exists($name, $this->options)) {
308308
throw new InvalidArgumentException(sprintf('Undefined option called: "%s"', $name));
309309
}
310-
$supportedApiVersions = $this->getSupportedApiVersions();
311-
if ('api_version' == $name && !in_array($value, $supportedApiVersions)) {
312-
throw new InvalidArgumentException(sprintf('Invalid API version ("%s"), valid are: %s', $name, implode(', ', $supportedApiVersions)));
313-
}
314310

315311
$this->options[$name] = $value;
316312
}
317313

318-
/**
319-
* Returns an array of valid API versions supported by this client.
320-
*
321-
* @return array
322-
*/
323-
public function getSupportedApiVersions()
324-
{
325-
return array('v3', 'beta');
326-
}
327-
328314
/**
329315
* @param string $name
330316
*

0 commit comments

Comments
 (0)