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

Slug uniqueness isn't verified #435

Open
Plaristote opened this issue May 7, 2015 · 2 comments
Open

Slug uniqueness isn't verified #435

Plaristote opened this issue May 7, 2015 · 2 comments
Labels

Comments

@Plaristote
Copy link

Greetings !

Recently one of our user had an issue while creating an article: it's a silly use case, because the user wanted to write two different articles with the same title.

Of course, this isn't possible, since the titles' uniquenesses are validated. But our user had a cunning idea: he added a point at the end of one of the title. That's when the problem appeared: we ended up with two different articles sharing the same slug... and the most recent being recorded as a draft.

As a consequence, when the users try to open the first article, they end up with a 404 error (because the first article found with this slug is a draft).

My question is: shouldn't the slugs be validated for uniqueness ? Is it already supposed to be the case ?

@parndt
Copy link
Member

parndt commented May 7, 2015

That seems like it should be a bug.. however can you, for now, ask your user not to try to cheat the system while a solution is devised? 😄

It might be as easy as adding a uniqueness validation for the slug column.

@bricesanchez
Copy link
Member

@Plaristote Could you provide us a pull request ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants