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

Changelog can't handle changed contenttypes with repeater fields #7573

Closed
doenietzomoeilijk opened this issue Jul 24, 2018 · 4 comments
Closed
Assignees
Labels
bug A bug that has been verified stale Stale issues & PRs flagged for closing

Comments

@doenietzomoeilijk
Copy link

doenietzomoeilijk commented Jul 24, 2018

If you enable the changelog and change a contenttype that has a repeater field, displaying that changelog entry will throw an error (array to string conversion) from twig.

Details

  • Relevant Bolt Version: 3.5
  • Install type: Composer install
  • PHP version: 7.1
  • Used web server: built-in dev server
  • For UX/UI issues: -

Reproduction

  • Install Bolt as per usual
  • Enable the changelog by setting changelog: enabled: to true
  • Add a contenttype with a repeater field. The default install has showcases, which work.
  • Add a record for the contenttype
  • Go to the changelog, find your change, try to view it
  • Boom headshot

Bug summary

The changelog view receives an array, where it actually expects a string. This makes sense, since repeaters are array-like things. Unfortunately, the array is empty, no matter what I changed in my repeater field. I'd have to dive into it to see if it's possible to get something to display there, but in the mean time, it'd be beneficial if at least the system wouldn't break at this. :)

For completeness' sake, the error is thrown at vendor/bolt/bolt/app/view/twig/changelog/_blocks.twig line 191 / 194, where the rendered changed fields are displayed.

@doenietzomoeilijk doenietzomoeilijk changed the title Changelog can't handle changed contenttypes with repeater fields [Bug] Changelog can't handle changed contenttypes with repeater fields Jul 24, 2018
@xiaohutai
Copy link
Member

Might be related to #7336

@doenietzomoeilijk
Copy link
Author

Oh, that certainly seems to be related - in fact, I'm fairly certain that issue will fix this one.

@bobdenotter any thought about getting #7336 moving again, now that #7291 seems to, in fact, have landed? :) And do you agree that this specific bug would be fixed by that, as well?

@bobdenotter
Copy link
Member

Yes, certainly the same issue.. I'll continue working on that one.

@bobdenotter bobdenotter self-assigned this Aug 8, 2018
@bobdenotter bobdenotter added the bug A bug that has been verified label Aug 8, 2018
@bobdenotter bobdenotter added this to the Bolt 3.6 - Feature release milestone Aug 8, 2018
@bobdenotter bobdenotter changed the title [Bug] Changelog can't handle changed contenttypes with repeater fields Changelog can't handle changed contenttypes with repeater fields Aug 8, 2018
@stale
Copy link

stale bot commented Oct 7, 2018

This issue has been automatically marked as stale because it has not had recent activity. Maybe this issue has been fixed in a recent release, or perhaps it is not affecting a lot of people?
It will be closed if no further activity occurs, because we like to keep the issue queue concise and actual.
If you think this issue is still relevant, please let us know. Especially if you’d like to help resolve the issue, either by helping us pinpointing the cause of a bug, or in implementing a fix or new feature.

@stale stale bot added the stale Stale issues & PRs flagged for closing label Oct 7, 2018
@stale stale bot closed this as completed Oct 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A bug that has been verified stale Stale issues & PRs flagged for closing
Projects
None yet
Development

No branches or pull requests

3 participants