Skip to content

Can't override EndlessCommand::DEFAULT_TIMEOUT #29

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

Closed
acim opened this issue Dec 5, 2016 · 2 comments
Closed

Can't override EndlessCommand::DEFAULT_TIMEOUT #29

acim opened this issue Dec 5, 2016 · 2 comments

Comments

@acim
Copy link
Contributor

acim commented Dec 5, 2016

This is used with self::DEFAULT_TIMEOUT and not with static::DEFAULT_TIMEOUT (late static binding), so it can't be overridden.

@mac-cain13
Copy link
Owner

Thanks for using this project!

I'm wondering why you want to override the constant, since it's the DEFAULT_TIMEOUT and you can set your own timeout by using setTimeout from for example the constructor. What would be the use case of overriding the constant?

@acim
Copy link
Contributor Author

acim commented Dec 6, 2016

I just think it is more elegant and transparent than always overriding the constructor. This class is made to be inherited, so it should allow such things. Just my opinion.

mac-cain13 added a commit that referenced this issue Dec 6, 2016
#29 Use late static binding for EndlessCommand::DEFAULT_TIMEOUT
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

No branches or pull requests

2 participants