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

subdomain and registerableDomain no longer work #80

Open
rkyoku opened this issue Feb 3, 2020 · 2 comments
Open

subdomain and registerableDomain no longer work #80

rkyoku opened this issue Feb 3, 2020 · 2 comments

Comments

@rkyoku
Copy link

rkyoku commented Feb 3, 2020

Hi,

subdomain and registerableDomain no longer seem to work with version 1.0.0 but they did work fine before updating the lib, with version 0.7.0.

@holtkamp
Copy link

holtkamp commented Mar 9, 2020

See #76 (comment), as of 1.0.0 you need to use https://github.com/jeremykendall/php-domain-parser directly yourself.

Also see #79

@jwage can you release a new patch version to prevent this kind of misunderstandings?

@flaviovs
Copy link

The biggest issue here IMHO is that access to $url->registerableDomain still works without any warnings (but always return null). Unless you do proper tests in your app, this would introduce bugs that are very difficult to track.

Fixing this is seems simple, though. Just change Purl/AbstractPart->get() to check if the key exists in $this->data and issue a PHP notice if not (this will mimic PHP's behaviour when accessing undefined properties).

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

3 participants