-
Notifications
You must be signed in to change notification settings - Fork 144
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
prevent problems for URL parameter that do no exist in Post model #514
Conversation
What other params would there be to be translated other than slug? Why not just explicitly translate slug and nothing else? |
I wanted to leave place for extensibility, if someone adds fields to the blog model, for example |
Shouldn't they just extend the event themselves in that case? |
would adding a new handler that adds the missing fields work? I have doubts... |
I have doubts about the original theoretical use case behind the original implementation, can you provide me a concrete example where someone would be using arbitrary columns from the DB table as URL params that they would also want translated? |
I can't. I don't mind changing it to only use the slug parameter as you suggested. |
LGTM! @bennothommo I'll leave it to you to merge so I don't screw up the release process. |
I submited the requested changes @bennothommo |
Thanks @mjauvin. |
A page with the following URL using the BlogPost component will generate an SQL query error when switching locale since the rainlab_blog_posts DB table does not have a field calld
category
: