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

Add process() method to WordPress_Sniff … #833

Merged
merged 1 commit into from
Feb 10, 2017

Conversation

jrfnl
Copy link
Member

@jrfnl jrfnl commented Feb 1, 2017

…and change to process_token() method in child classes.

This saves us having to call $this->init() from every child class, always sets the basic properties and makes them available to the child classes.

This PR addresses the third bullet from issue #765

P.S.: For the CronInterval sniff, the changes have been kept to a minimum to avoid large conflicts with #818. As #818 has been merged, fixed up the CronInterval sniff to be inline with the rest of the PR.

…n()` method in child classes.

This saves us having to call `$this->init()` from every child class, always sets the basic properties and makes them available to the child classes.
@jrfnl jrfnl force-pushed the feature/simplify-use-WP-sniff-class branch from 37593b7 to d5dabfc Compare February 10, 2017 18:56
@jrfnl
Copy link
Member Author

jrfnl commented Feb 10, 2017

Rebased for merge conflict

Copy link
Contributor

@JDGrimes JDGrimes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's do it.

Note that I compared the performance of this with current develop, and there is almost no difference at all.

Because I'm obsessed with performance of a tool that is just used to sniff my actual code. Yeah.

@JDGrimes JDGrimes merged commit aa75d75 into develop Feb 10, 2017
@JDGrimes JDGrimes deleted the feature/simplify-use-WP-sniff-class branch February 10, 2017 19:47
@jrfnl
Copy link
Member Author

jrfnl commented Feb 10, 2017

@JDGrimes Thanks & thanks for keeping an eye on performance. As for the most part the functionality used hasn't changed, just the way it is called, your findings are in line with what I expected.

@jrfnl
Copy link
Member Author

jrfnl commented Feb 10, 2017

Let me tidy up the follow up branch & I'll try & pull it later today (as in Florida today)

@JDGrimes
Copy link
Contributor

😎

@jrfnl
Copy link
Member Author

jrfnl commented Feb 11, 2017

Ok, pulled - see #841

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

3 participants