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

Allow null $location param in the constructor and sanitize it #25

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

belyas
Copy link

@belyas belyas commented Sep 18, 2017

For type-hinting reason, we should set $location parameter in the constructor of WebSitemapItem class to null value which enables to use setLocation method from type-hinting

@o
Copy link
Owner

o commented Sep 19, 2017

Hi @belyas The new version is still in progress. I am planning to finish to end of this month.
https://github.com/o/sitemap-php/milestone/1

I just checked the sitemap spec, it seems location is required, this is why I kept location in constructor. And I am not sure about sanitize location. I want to keep this function flexible for every user.

So, everything is still in progress, lets discuss after a few days. Still I have to refactor and implement lots of things in library.

(But today you can use the library from packagist https://packagist.org/packages/osm/sitemap-php, be careful lots of thing (API, structure) will be change)

@belyas
Copy link
Author

belyas commented Oct 4, 2017

Hi @o ,

Alright, I see I'll be back later to have a look at it

Good luck :)

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.

2 participants