Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Coding standards, getting rid of singleton in OOP example, making sure no class/function collisions happen #5

Merged
merged 4 commits into from Oct 19, 2012

Conversation

rinatkhaziev
Copy link
Contributor

Hey,

Got some time to fix potential issues:

  1. got rid of singleton in OOP example. Here's why: say two plugin authors use WeDevs::getInstance(), what will happen is one's properties would be overwritten by other ones. It's probably better to make getInstance method return new instance each time it's called. After all, you intended this class to be used in multiple plugins.
  1. added a buch of class|function_checks
  2. WP coding standards.

tareq1988 added a commit that referenced this pull request Oct 19, 2012
Coding standards, getting rid of singleton in OOP example, making sure no class/function collisions happen
@tareq1988 tareq1988 merged commit 5a35302 into tareq1988:master Oct 19, 2012
@tareq1988
Copy link
Owner

You are right about the singleton pattern.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants