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

Path /content/[type]/ for non-existent content types should 404 #1854

Open
gRegorLove opened this issue Aug 11, 2017 · 3 comments
Open

Path /content/[type]/ for non-existent content types should 404 #1854

gRegorLove opened this issue Aug 11, 2017 · 3 comments

Comments

@gRegorLove
Copy link

While trying to do this:

I was manually poking around URLs on different Known sites to compare /content/likes/, even though likes were not advertised in the Filter Content dropdown. I didn't find the (non-existent) likes, but the default stream displayed instead.

What I expected

If the content type doesn't exist, it should render a 404 (or possible a 302 redirect to the default stream).

Some other notes:

This appears to happen with any arbitrary [type] in the path, e.g. /content/florps/

@mapkyca
Copy link
Member

mapkyca commented Aug 12, 2017

That's /Idno/Pages/Homepage.php that's responsible for this. Little tricky to do a straight 404 as this page can accept multiple types, so it'd have to 404 only if all those types are unsupported - which is different from supported, but not found.

Arguably both these cases could 404, but I'd look at best practice for guidance on this.

@gRegorLove
Copy link
Author

I don't known Known internals, but yes ideally it should check if the type is supported / exists and return 404 when it doesn't. I think a temporary redirect is also OK, but 404 is preferred since it's more accurate. Search engines can penalize sites that deliver the same content on multiple URLs. This is certainly a lower-priority thing since I was manually assembling these URLs, not finding them linked anywhere.

@mapkyca
Copy link
Member

mapkyca commented Aug 12, 2017

Well, unknown types shouldn't be being linked to so shouldn't be that much of an issue.

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