-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Error message 'can't convert array to string' when using content.order.by with a taxonomy #1264
Comments
I have tested this, we both cannot replicate locally the problem, with the same |
Can you provide the exact code you are using so i can take a look? |
Sure, so it errors in two places. The admin areas when you try and accessing the 'pages' section, and the front end 'case-studies' page errors. Within the case-studies frontmatter we have:
You can see the frontend error message here: https://www.draytonpartners.com/case-studies Attached is a screenshot of the error message in the admin area and the stack trace was pasted into the original comment. If you need more specific code, let me know. Cheers! |
Also the blueprint is as follows:
Which, I believe (it's been a while since I've touched this code), when saved in the frontmatter of the case-studies child pages becomes:
|
Ok, i was just looking at this order stuff on collection pages today. It currently only supports one level under ' |
Fixed in develop |
Previously (and currently when testing locally) the live environment of our site would allow us to order the collection by the taxonomy. This meant that we could group together particular tags - each article would only have one tag. I appreciate that this could then create an array, and therefore the error message could appear, but this never used to happen (is this by pure happenstance?) and still doesn't happen on my local environment. In fact, Flavio has also tested the site, and it doesn't occur for him locally either.
To prevent the error showing on the front end for now, I have set it to order.by:default. However, I can break it again to show you if requested.
Steps taken to isolate the error so far include:
For reference the stack trace I was getting is as follows:
cc/ @flaviocopes
The text was updated successfully, but these errors were encountered: