aboutsummaryrefslogtreecommitdiffstats
path: root/includes/actions/WatchAction.php
diff options
context:
space:
mode:
authorhmonroy <hmonroy@wikimedia.org>2020-07-22 18:24:42 -0700
committerhmonroy <hmonroy@wikimedia.org>2020-08-14 11:47:03 -0700
commit0c2cc49bdcad84aa2d3b450ecae723a831d9dbe7 (patch)
tree37038afc84217ee93490bdac580b14925c4fc80c /includes/actions/WatchAction.php
parent0de9d89e3727ab17f08158600428dad6c678ff83 (diff)
downloadmediawikicore-0c2cc49bdcad84aa2d3b450ecae723a831d9dbe7.tar.gz
mediawikicore-0c2cc49bdcad84aa2d3b450ecae723a831d9dbe7.zip
Update language in watchlist expiry
Update watchlist expiry language indicators (dropdowns, tooltips, watch via star, watch via edit): * Change "Permanently" to "Permanent" * Change "XX days left" and "Expires in X days" to "XX days left in watchlist" * Update the "Click.." sentence by star to "Click to remove it." * Change watch period for a page that is less than "1 day left" to "A few hours left" Bug: T253135 Bug: T255632 Change-Id: I114c6f77e86ad81b1810fedcd49f52c88700ca16
Diffstat (limited to 'includes/actions/WatchAction.php')
-rw-r--r--includes/actions/WatchAction.php3
1 files changed, 1 insertions, 2 deletions
diff --git a/includes/actions/WatchAction.php b/includes/actions/WatchAction.php
index 7fe5b8f0cad5..dc8cdcecb605 100644
--- a/includes/actions/WatchAction.php
+++ b/includes/actions/WatchAction.php
@@ -131,8 +131,7 @@ class WatchAction extends FormAction {
// If it's already being temporarily watched,
// add the existing expiry as the default option in the dropdown.
$expiry = MWTimestamp::getInstance( $watchedItem->getExpiry() );
- $diffInDays = $watchedItem->getExpiryInDays();
- $daysLeft = $msgLocalizer->msg( 'watchlist-expiry-days-left', [ $diffInDays ] )->text();
+ $daysLeft = $watchedItem->getExpiryInDaysText( $msgLocalizer, true );
$expiryOptions = array_merge(
[ $daysLeft => $expiry->getTimestamp( TS_MW ) ],
$expiryOptions