biswa457 / 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

Adopt the PSR-1 standard, avoid side-effects #349

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
As per http://www.php-fig.org/psr/1/, section 2.3:

    A file SHOULD declare new symbols (classes, functions, constants, etc.) and cause no other side effects, or it SHOULD execute logic with side effects, but SHOULD NOT do both.

    The phrase "side effects" means execution of logic not directly related to declaring classes, functions, constants, etc., merely from including the file.

Just including Google_Client.php will adjust include paths, load additional 
files that define globals and may even throw exceptions.

Original issue reported on code.google.com by vdelau on 19 Jul 2013 at 12:16

GoogleCodeExporter commented 8 years ago
Agreed - we're aiming to get to PRS 1 in 1.0.0, though currently that doesn't 
include autoloading, so there will still be some side effect. That may change 
of course!

Original comment by ianbar...@google.com on 23 Jul 2013 at 12:01

GoogleCodeExporter commented 8 years ago
I'm looking forward to it! :D

Original comment by marc...@gmail.com on 21 Aug 2013 at 6:52

GoogleCodeExporter commented 8 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