Issue 11189: Fix notifications for new posts
This commit is contained in:
parent
ec897c6c85
commit
cd0a0c3424
2 changed files with 72 additions and 56 deletions
|
@ -140,7 +140,7 @@ class Notification extends BaseFactory implements ICanCreateFromTableRow
|
||||||
$title = '';
|
$title = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->logger->debug('Got verb and type', ['verb' => $Notification->verb, 'type' => $Notification->type]);
|
$this->logger->debug('Got verb and type', ['verb' => $Notification->verb, 'type' => $Notification->type, 'causer' => $causer['id'], 'author' => $author['id'], 'item' => $item['id'], 'uid' => $Notification->uid]);
|
||||||
|
|
||||||
switch ($Notification->verb) {
|
switch ($Notification->verb) {
|
||||||
case Activity::LIKE:
|
case Activity::LIKE:
|
||||||
|
@ -239,6 +239,18 @@ class Notification extends BaseFactory implements ICanCreateFromTableRow
|
||||||
case Post\UserNotification::TYPE_DIRECT_THREAD_COMMENT:
|
case Post\UserNotification::TYPE_DIRECT_THREAD_COMMENT:
|
||||||
$msg = $userL10n->t('%1$s commented on your thread %2$s');
|
$msg = $userL10n->t('%1$s commented on your thread %2$s');
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case Post\UserNotification::TYPE_SHARED:
|
||||||
|
if (($causer['id'] != $author['id']) && ($title != '')) {
|
||||||
|
$msg = $userL10n->t('%1$s shared the post %2$s from %3$s');
|
||||||
|
} elseif ($causer['id'] != $author['id']) {
|
||||||
|
$msg = $userL10n->t('%1$s shared a post from %3$s');
|
||||||
|
} elseif ($title != '') {
|
||||||
|
$msg = $userL10n->t('%1$s shared the post %2$s');
|
||||||
|
} else {
|
||||||
|
$msg = $userL10n->t('%1$s shared a post');
|
||||||
|
}
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,7 +8,7 @@ msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: 2021.12-rc\n"
|
"Project-Id-Version: 2021.12-rc\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2022-01-24 04:58+0000\n"
|
"POT-Creation-Date: 2022-01-28 05:23+0000\n"
|
||||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||||
|
@ -118,7 +118,7 @@ msgid "The feed for this item is unavailable."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/editpost.php:38 mod/events.php:220 mod/follow.php:56 mod/follow.php:130
|
#: mod/editpost.php:38 mod/events.php:220 mod/follow.php:56 mod/follow.php:130
|
||||||
#: mod/item.php:185 mod/item.php:190 mod/item.php:937 mod/message.php:69
|
#: mod/item.php:185 mod/item.php:190 mod/item.php:940 mod/message.php:69
|
||||||
#: mod/message.php:111 mod/notes.php:44 mod/ostatus_subscribe.php:32
|
#: mod/message.php:111 mod/notes.php:44 mod/ostatus_subscribe.php:32
|
||||||
#: mod/photos.php:160 mod/photos.php:897 mod/repair_ostatus.php:31
|
#: mod/photos.php:160 mod/photos.php:897 mod/repair_ostatus.php:31
|
||||||
#: mod/settings.php:46 mod/settings.php:56 mod/settings.php:412
|
#: mod/settings.php:46 mod/settings.php:56 mod/settings.php:412
|
||||||
|
@ -518,19 +518,19 @@ msgstr ""
|
||||||
msgid "Empty post discarded."
|
msgid "Empty post discarded."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/item.php:743
|
#: mod/item.php:746
|
||||||
msgid "Post updated."
|
msgid "Post updated."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/item.php:753 mod/item.php:758
|
#: mod/item.php:756 mod/item.php:761
|
||||||
msgid "Item wasn't stored."
|
msgid "Item wasn't stored."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/item.php:769
|
#: mod/item.php:772
|
||||||
msgid "Item couldn't be fetched."
|
msgid "Item couldn't be fetched."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/item.php:915 src/Module/Admin/Themes/Details.php:39
|
#: mod/item.php:918 src/Module/Admin/Themes/Details.php:39
|
||||||
#: src/Module/Admin/Themes/Index.php:59 src/Module/Debug/ItemBody.php:41
|
#: src/Module/Admin/Themes/Index.php:59 src/Module/Debug/ItemBody.php:41
|
||||||
#: src/Module/Debug/ItemBody.php:56
|
#: src/Module/Debug/ItemBody.php:56
|
||||||
msgid "Item not found."
|
msgid "Item not found."
|
||||||
|
@ -3655,201 +3655,201 @@ msgstr ""
|
||||||
msgid "Could not connect to database."
|
msgid "Could not connect to database."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:425
|
#: src/Core/L10n.php:399 src/Model/Event.php:425
|
||||||
#: src/Module/Settings/Display.php:182
|
#: src/Module/Settings/Display.php:182
|
||||||
msgid "Monday"
|
msgid "Monday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:426
|
#: src/Core/L10n.php:399 src/Model/Event.php:426
|
||||||
msgid "Tuesday"
|
msgid "Tuesday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:427
|
#: src/Core/L10n.php:399 src/Model/Event.php:427
|
||||||
msgid "Wednesday"
|
msgid "Wednesday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:428
|
#: src/Core/L10n.php:399 src/Model/Event.php:428
|
||||||
msgid "Thursday"
|
msgid "Thursday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:429
|
#: src/Core/L10n.php:399 src/Model/Event.php:429
|
||||||
msgid "Friday"
|
msgid "Friday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:430
|
#: src/Core/L10n.php:399 src/Model/Event.php:430
|
||||||
msgid "Saturday"
|
msgid "Saturday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:377 src/Model/Event.php:424
|
#: src/Core/L10n.php:399 src/Model/Event.php:424
|
||||||
#: src/Module/Settings/Display.php:182
|
#: src/Module/Settings/Display.php:182
|
||||||
msgid "Sunday"
|
msgid "Sunday"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:445
|
#: src/Core/L10n.php:403 src/Model/Event.php:445
|
||||||
msgid "January"
|
msgid "January"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:446
|
#: src/Core/L10n.php:403 src/Model/Event.php:446
|
||||||
msgid "February"
|
msgid "February"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:447
|
#: src/Core/L10n.php:403 src/Model/Event.php:447
|
||||||
msgid "March"
|
msgid "March"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:448
|
#: src/Core/L10n.php:403 src/Model/Event.php:448
|
||||||
msgid "April"
|
msgid "April"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Core/L10n.php:401 src/Model/Event.php:436
|
#: src/Core/L10n.php:403 src/Core/L10n.php:423 src/Model/Event.php:436
|
||||||
msgid "May"
|
msgid "May"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:449
|
#: src/Core/L10n.php:403 src/Model/Event.php:449
|
||||||
msgid "June"
|
msgid "June"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:450
|
#: src/Core/L10n.php:403 src/Model/Event.php:450
|
||||||
msgid "July"
|
msgid "July"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:451
|
#: src/Core/L10n.php:403 src/Model/Event.php:451
|
||||||
msgid "August"
|
msgid "August"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:452
|
#: src/Core/L10n.php:403 src/Model/Event.php:452
|
||||||
msgid "September"
|
msgid "September"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:453
|
#: src/Core/L10n.php:403 src/Model/Event.php:453
|
||||||
msgid "October"
|
msgid "October"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:454
|
#: src/Core/L10n.php:403 src/Model/Event.php:454
|
||||||
msgid "November"
|
msgid "November"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:381 src/Model/Event.php:455
|
#: src/Core/L10n.php:403 src/Model/Event.php:455
|
||||||
msgid "December"
|
msgid "December"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:417
|
#: src/Core/L10n.php:419 src/Model/Event.php:417
|
||||||
msgid "Mon"
|
msgid "Mon"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:418
|
#: src/Core/L10n.php:419 src/Model/Event.php:418
|
||||||
msgid "Tue"
|
msgid "Tue"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:419
|
#: src/Core/L10n.php:419 src/Model/Event.php:419
|
||||||
msgid "Wed"
|
msgid "Wed"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:420
|
#: src/Core/L10n.php:419 src/Model/Event.php:420
|
||||||
msgid "Thu"
|
msgid "Thu"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:421
|
#: src/Core/L10n.php:419 src/Model/Event.php:421
|
||||||
msgid "Fri"
|
msgid "Fri"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:422
|
#: src/Core/L10n.php:419 src/Model/Event.php:422
|
||||||
msgid "Sat"
|
msgid "Sat"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:397 src/Model/Event.php:416
|
#: src/Core/L10n.php:419 src/Model/Event.php:416
|
||||||
msgid "Sun"
|
msgid "Sun"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:432
|
#: src/Core/L10n.php:423 src/Model/Event.php:432
|
||||||
msgid "Jan"
|
msgid "Jan"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:433
|
#: src/Core/L10n.php:423 src/Model/Event.php:433
|
||||||
msgid "Feb"
|
msgid "Feb"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:434
|
#: src/Core/L10n.php:423 src/Model/Event.php:434
|
||||||
msgid "Mar"
|
msgid "Mar"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:435
|
#: src/Core/L10n.php:423 src/Model/Event.php:435
|
||||||
msgid "Apr"
|
msgid "Apr"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:437
|
#: src/Core/L10n.php:423 src/Model/Event.php:437
|
||||||
msgid "Jun"
|
msgid "Jun"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:438
|
#: src/Core/L10n.php:423 src/Model/Event.php:438
|
||||||
msgid "Jul"
|
msgid "Jul"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:439
|
#: src/Core/L10n.php:423 src/Model/Event.php:439
|
||||||
msgid "Aug"
|
msgid "Aug"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401
|
#: src/Core/L10n.php:423
|
||||||
msgid "Sep"
|
msgid "Sep"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:441
|
#: src/Core/L10n.php:423 src/Model/Event.php:441
|
||||||
msgid "Oct"
|
msgid "Oct"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:442
|
#: src/Core/L10n.php:423 src/Model/Event.php:442
|
||||||
msgid "Nov"
|
msgid "Nov"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:401 src/Model/Event.php:443
|
#: src/Core/L10n.php:423 src/Model/Event.php:443
|
||||||
msgid "Dec"
|
msgid "Dec"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:420
|
#: src/Core/L10n.php:442
|
||||||
msgid "poke"
|
msgid "poke"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:420
|
#: src/Core/L10n.php:442
|
||||||
msgid "poked"
|
msgid "poked"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:421
|
#: src/Core/L10n.php:443
|
||||||
msgid "ping"
|
msgid "ping"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:421
|
#: src/Core/L10n.php:443
|
||||||
msgid "pinged"
|
msgid "pinged"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:422
|
#: src/Core/L10n.php:444
|
||||||
msgid "prod"
|
msgid "prod"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:422
|
#: src/Core/L10n.php:444
|
||||||
msgid "prodded"
|
msgid "prodded"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:423
|
#: src/Core/L10n.php:445
|
||||||
msgid "slap"
|
msgid "slap"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:423
|
#: src/Core/L10n.php:445
|
||||||
msgid "slapped"
|
msgid "slapped"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:424
|
#: src/Core/L10n.php:446
|
||||||
msgid "finger"
|
msgid "finger"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:424
|
#: src/Core/L10n.php:446
|
||||||
msgid "fingered"
|
msgid "fingered"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:425
|
#: src/Core/L10n.php:447
|
||||||
msgid "rebuff"
|
msgid "rebuff"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Core/L10n.php:425
|
#: src/Core/L10n.php:447
|
||||||
msgid "rebuffed"
|
msgid "rebuffed"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -9988,21 +9988,25 @@ msgid "%1$s shared your post %2$s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Navigation/Notifications/Factory/Notification.php:176
|
#: src/Navigation/Notifications/Factory/Notification.php:176
|
||||||
|
#: src/Navigation/Notifications/Factory/Notification.php:245
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "%1$s shared the post %2$s from %3$s"
|
msgid "%1$s shared the post %2$s from %3$s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Navigation/Notifications/Factory/Notification.php:178
|
#: src/Navigation/Notifications/Factory/Notification.php:178
|
||||||
|
#: src/Navigation/Notifications/Factory/Notification.php:247
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "%1$s shared a post from %3$s"
|
msgid "%1$s shared a post from %3$s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Navigation/Notifications/Factory/Notification.php:180
|
#: src/Navigation/Notifications/Factory/Notification.php:180
|
||||||
|
#: src/Navigation/Notifications/Factory/Notification.php:249
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "%1$s shared the post %2$s"
|
msgid "%1$s shared the post %2$s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Navigation/Notifications/Factory/Notification.php:182
|
#: src/Navigation/Notifications/Factory/Notification.php:182
|
||||||
|
#: src/Navigation/Notifications/Factory/Notification.php:251
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "%1$s shared a post"
|
msgid "%1$s shared a post"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
Loading…
Reference in a new issue