Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

Support

Comments breaks contact

Started by Ian 7 years ago · 1 replies · 732 views
7 years ago

I'm having a problem with the comments plugin. It works as expected but once a comment has been added to a given post, the contact page stops working with the following error:
"Unable to add function "recent_comments" as extensions have already been initialized."

Note that the contact page does not call the comments twig, which is only called in the blog item twig while the comments page uses the default twig.

7 years ago

For posterity...

When I posted I was imagining the problem to be with the comments plugin as I've had it cause the same error in other situations.

However it turns out to be the reCAPTCHA Contact plugin that's buggy in this case.

Solution: In comments.yaml, disable the route associated with the contact page (i.e. /contact).

last edited 04/16/19 by Ian

Suggested topics

Topic Participants Replies Views Activity
Support · by Thomas, 1 week ago
3 66 20 minutes ago
Support · by Anna, 3 days ago
2 72 21 hours ago
Support · by Justin Young, 22 hours ago
1 40 22 hours ago
Support · by Duc , 1 week ago
2 76 6 days ago
Support · by Colin Hume, 1 week ago
2 70 6 days ago