setPublished(bool) not supported in D9

Created on 12 April 2022, about 3 years ago
Updated 9 April 2023, about 2 years ago

Problem/Motivation

Since Drupal 9 the bool parameter for setPublished(bool) is removed.
The code for marking a node (and comment) as spam should implement this.

Steps to reproduce

mark a node or comment as spam in a Drupal 9+ website.

Proposed resolution

Modify code in UnpublishReportNode.php, UnpublishReportComment.php and check the rest of the code for other occurrences.
See also https://www.drupal.org/project/akismet/issues/3274732#comment-14477950 🐛 "Report to Akismet and unpublish" not working on Comments Closed: duplicate

Remaining tasks

User interface changes

None.

API changes

None.

Data model changes

None.

🐛 Bug report
Status

Closed: duplicate

Version

1.0

Component

Code

Created by

🇳🇱Netherlands mvbaalen

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024