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

Update audit log message for comments transitioning status #1430

Conversation

goldenapples
Copy link
Contributor

@goldenapples goldenapples commented Apr 20, 2023

This adds the post title to the audit log text for comments that are transitioning status, to be consistent with the other messages in the comments connector.

Describe your approach and how it fixes the issue.

Checklist

  • Project documentation has been updated to reflect the changes in this pull request, if applicable.
  • I have tested the changes in the local development environment (see contributing.md).
  • I have added phpunit tests.

Release Changelog

  • Fix: Makes the log messages for comments transitioning status (approved, unapproved, marked as spam, deleted, etc.) consistent with the other messages generated by the Comments Connector by including the post title in the message.

Release Checklist

  • This pull request is to the master branch.
  • Release version follows semantic versioning. Does it include breaking changes?
  • Update changelog in readme.txt.
  • Bump version in stream.php.
  • Bump Stable tag in readme.txt.
  • Bump version in classes/class-plugin.php.
  • Draft a release on GitHub.

Change [ ] to [x] to mark the items as done.

This adds the post title to the audit log text for comments that are
transitioning status, to be consistent with the other messages in the
comments connector.
@goldenapples goldenapples force-pushed the update-comment-status-transition-log-messages branch from a143d50 to 547cb03 Compare April 20, 2023 21:19
Copy link
Contributor

@kasparsd kasparsd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution! Please see the one suggestion inline the pull request!

connectors/class-connector-comments.php Show resolved Hide resolved
@kasparsd kasparsd merged commit 2de9866 into xwp:develop Sep 13, 2023
1 check passed
@kasparsd
Copy link
Contributor

@goldenapples Looks like the missing CI runs for this pull request did actually introduce a regression for the unit tests:

https://github.com/xwp/stream/actions/runs/6178185169/job/16770933181?pr=1448#step:9:60

Would you be able to create a follow-up pull request to fix that test?

'%1$s\'s %3$s %2$s',
'Comment status transition. 1: Comment author, 2: Post title, 3: Comment type',
'stream'

kasparsd added a commit that referenced this pull request Sep 14, 2023
Fix tests after comment translation change in #1430
goldenapples added a commit to goldenapples/stream that referenced this pull request Sep 14, 2023
Updates the test assertion for this method to match the new log output.
@goldenapples
Copy link
Contributor Author

Just opened a PR to fix the unit test, #1450. I didn't run tests locally, and they're not set to run on forks, but I updated the assertion to match the expected output.

@goldenapples goldenapples deleted the update-comment-status-transition-log-messages branch September 14, 2023 12:06
kasparsd added a commit that referenced this pull request Sep 27, 2023
@kasparsd kasparsd mentioned this pull request Oct 9, 2023
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants