php-github-api
php-github-api copied to clipboard
Do not "help" the user by changing parameters
On 30+ places we have code like this:
if (!in_array($state, array('open', 'closed'))) {
$state = 'open';
}
If the user misspelled the $state
we should not help them. That may cause unpredicted actions. We should throw an exception or let the API call fail.
This is a BC break. I've marked it in milestone 3.0.
Has this already been done in v3?
@dereuromark no this was not done in 3.0. So it will likely be done for 4.0 with deprecations of the current behaviour in 3.x