Skip to content

Commit

Permalink
Bulk status change: Fix bulk rejection (#1486)
Browse files Browse the repository at this point in the history
* Use the correct action name

* Correct the same action name in another situations

Co-authored-by: Jesús Amieiro <1667814+amieiro@users.noreply.github.com>
  • Loading branch information
dd32 and amieiro committed Sep 19, 2022
1 parent 622a7ce commit 1022594
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions gp-includes/routes/translation.php
Expand Up @@ -422,7 +422,7 @@ private function _bulk_approve( $bulk ) {
case 'approve':
$new_status = 'current';
break;
case 'rejected':
case 'reject':
$new_status = 'rejected';
break;
case 'changesrequested':
Expand Down Expand Up @@ -451,7 +451,7 @@ private function _bulk_approve( $bulk ) {
$ok
);
break;
case 'rejected':
case 'reject':
$this->notices[] = sprintf(
/* translators: %d: Translations count. */
_n( '%d translation was rejected.', '%d translations were rejected.', $ok, 'glotpress' ),
Expand All @@ -476,7 +476,7 @@ private function _bulk_approve( $bulk ) {
$error
);
break;
case 'rejected':
case 'reject':
$message = sprintf(
/* translators: %s: Translations count. */
_n( 'Error with rejecting %s translation.', 'Error with rejecting %s translations.', $error, 'glotpress' ),
Expand All @@ -500,7 +500,7 @@ private function _bulk_approve( $bulk ) {
$ok
);
break;
case 'rejected':
case 'reject':
$message .= sprintf(
/* translators: %s: Translations count. */
_n( 'The remaining %s translation was rejected successfully.', 'The remaining %s translations were rejected successfully.', $ok, 'glotpress' ),
Expand All @@ -525,7 +525,7 @@ private function _bulk_approve( $bulk ) {
$error
);
break;
case 'rejected':
case 'reject':
$this->errors[] = sprintf(
/* translators: %s: Translations count. */
_n( 'Error with rejecting %s translation.', 'Error with rejecting all %s translations.', $error, 'glotpress' ),
Expand Down

0 comments on commit 1022594

Please sign in to comment.