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

Visitor interface implementation. #322

Merged
merged 3 commits into from Jun 19, 2014

Conversation

czolnowski
Copy link
Contributor

Hook which give possibility to manipulate Visitor object instance. I've used same convention which is implemented in Tracker class. (https://github.com/piwik/piwik/blob/master/core/Tracker.php#L631) This hook could be used to overwrite some fields in Live plugin API methods. Interface is simply as possible. Only two methods should be visible outside of Visitor class. (in my, and my phpstorm opinion)

@mattab
Copy link
Member

mattab commented Jun 18, 2014

Build failed on php 5.4/3 see here: https://travis-ci.org/piwik/piwik/jobs/27848196

PHP Fatal error: Using $this when not in object context in /home/travis/build/piwik/piwik/plugins/Live/API.php on line 557

Otherwise the PR looks good! I created ticket #5360 New hook Live.makeNewVisitorObject for plugins to customise Visitor object
http://dev.piwik.org/trac/ticket/5360#ticket

@czolnowski
Copy link
Contributor Author

I will fix this context error.

mattab pushed a commit that referenced this pull request Jun 19, 2014
Visitor interface implementation. Fixes #5360
@mattab mattab merged commit 6c19704 into matomo-org:master Jun 19, 2014
@mattab
Copy link
Member

mattab commented Jun 19, 2014

ping @tsteur - this is another use case for Dependency injection 👍

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