boyfinal / google-api-php-client

Automatically exported from code.google.com/p/google-api-php-client
Apache License 2.0
0 stars 0 forks source link

Notice: Undefined index: errors in google-api-php-client/src/io/Google_REST.php on line 66 #266

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. request to https://www.googleapis.com/blogger/v3/users/<here wrong user 
ID>/blogs

answer from the service:
{
 "error": {
  "code": 500,
  "message": null
 }
}

Original issue reported on code.google.com by mv.des...@gmail.com on 11 Feb 2013 at 2:51

GoogleCodeExporter commented 9 years ago
Looks like either some unintended variation in the naming from the service, or 
we've got the wrong key in there. 

Original comment by ianbar...@google.com on 22 Mar 2013 at 6:06

GoogleCodeExporter commented 9 years ago
so it must be validated before throw :)  at least isset()

something like this

//throw new Google_ServiceException($err, $code, null, 
$decoded['error']['errors']);
$error_msg = $err;
if(isset($decoded['error']) && isset($decoded['error']['errors'])){
  $error_msg = $decoded['error']['errors'];
}
throw new Google_ServiceException($err, $code, null, $error_msg);

Original comment by mv.des...@gmail.com on 22 Mar 2013 at 7:06

GoogleCodeExporter commented 9 years ago
This issue is now open for quite a time. we're receiving this error quite often 
in our app and it would be super, if the code from #2 would be merged into 
master! any chance for a priority-boost?

Original comment by johannes...@socialisten.at on 8 Jan 2014 at 8:47

GoogleCodeExporter commented 9 years ago
This issue tracker is now closing. Development on the Google PHP client library 
moved to GitHub with the release of the 1.0.0-alpha, and now the 1.0 branch has 
reached beta status there will be no further releases of the 0.6 branch of the 
library. 

Please take a look at the latest version on 
https://github.com/google/google-api-php-client

For information on migrating, please take a look at this guide: 
https://developers.google.com/api-client-library/php/guide/migration

For general library support please ask a question on StackOverflow: 
http://stackoverflow.com/questions/tagged/google-api-php-client

If you are looking for support with a specific API, please contact the team 
working with that API via StackOverflow or their preferred support mechanism. 

If your issue still exists with the new version of the library, please raise a 
bug in the GitHub issue tracker with a minimal code sample. 

Thanks!

Original comment by ianbar...@google.com on 22 Jan 2014 at 4:53