-
Notifications
You must be signed in to change notification settings - Fork 34
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
added a view-helper to get the primary-language #106
added a view-helper to get the primary-language #106
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure we need this helper but I guess you have a use case if you created this PR :)
can you rebase to develop branch?
*/ | ||
namespace SlmLocale\Service; | ||
|
||
use Interop\Container\ContainerInterface; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this can be Psr\Container\ContainerInterface
as we require ServiceManager ^3.2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Zend\ServiceManager\Factory\FactoryInterface
is still using Interop\Container\ContainerInterface
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm, it looks we need to update servicemanager because they support PSR only from 3.4.0 but I guess if this is final we can change this anytime.
use SlmLocale\View\Helper\PrimaryLanguage; | ||
use Zend\ServiceManager\Factory\FactoryInterface; | ||
|
||
class PrimaryLanguageHelperFactory implements FactoryInterface |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need to implement FactoryInterface
? also, make factory final
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the factory 'FactoryInterface' is for me zf standard
use Locale; | ||
use Zend\View\Helper\AbstractHelper; | ||
|
||
class PrimaryLanguage extends AbstractHelper |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make it final class
still not rebased to develop. Will do when I merge. |
45870a6
to
81fa578
Compare
maybe other ppl need it too =)