verbb / comments

A Craft CMS plugin for managing comments directly within the CMS.
Other
137 stars 35 forks source link

TypeError: Cannot assign string to property craft\base\Element::$siteld #293

Closed arifje closed 10 months ago

arifje commented 10 months ago

Describe the bug

We've updated the plugin including some templates, but now we're getting an error when submitting a comment due to a missing siteId.

{{ commentsQuery.siteId }} doesn't return a valid value in the form template (includes/form.html), resulting in an error.

{{ element.siteId }} does work, which was in our old template too, so I temporary changed this back. Now submitting works again.

The errror:

Screenshot 2023-11-11 at 13 07 25

On another site it's working with the latest version, but that is not a multi site. This one is.

Steps to reproduce

Create a comment on a multi site installation

Craft CMS version

4.5.9

Plugin version

2.0.8

Multi-site?

Yes

Additional context

No response

engram-design commented 10 months ago

Fixed for the next release. To get this early run composer require verbb/comments:"dev-craft-4 as 2.0.8"

engram-design commented 10 months ago

Fixed in 2.0.9