Number parameters in messages that have multiple parameters
Trim trailing whitespace Leading tabs to spaces Remove superfluous whitespace
This commit is contained in:
parent
0e2d9432b5
commit
3e60d4cb3f
@ -44,7 +44,6 @@ if (!defined('STATUSNET')) {
|
||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class ActivityPlugin extends Plugin
|
||||
{
|
||||
const VERSION = '0.1';
|
||||
@ -84,12 +83,12 @@ class ActivityPlugin extends Plugin
|
||||
if (!empty($user)) {
|
||||
$sub = Subscription::pkeyGet(array('subscriber' => $subscriber->id,
|
||||
'subscribed' => $other->id));
|
||||
$rendered = sprintf(_m('<a href="%s">%s</a> started following <a href="%s">%s</a>.'),
|
||||
$rendered = sprintf(_m('<a href="%1$s">%2$s</a> started following <a href="%2$s">%4$s</a>.'),
|
||||
$subscriber->profileurl,
|
||||
$subscriber->getBestName(),
|
||||
$other->profileurl,
|
||||
$other->getBestName());
|
||||
$content = sprintf(_m('%s (%s) started following %s (%s).'),
|
||||
$content = sprintf(_m('%1$s (%2$s) started following %3$s (%4$s).'),
|
||||
$subscriber->getBestName(),
|
||||
$subscriber->profileurl,
|
||||
$other->getBestName(),
|
||||
@ -114,12 +113,12 @@ class ActivityPlugin extends Plugin
|
||||
if(!$this->StopFollowUser) return true;
|
||||
$user = $subscriber->getUser();
|
||||
if (!empty($user)) {
|
||||
$rendered = sprintf(_m('<a href="%s">%s</a> stopped following <a href="%s">%s</a>.'),
|
||||
$rendered = sprintf(_m('<a href="%1$s">%2$s</a> stopped following <a href="%3$s">%4$s</a>.'),
|
||||
$subscriber->profileurl,
|
||||
$subscriber->getBestName(),
|
||||
$other->profileurl,
|
||||
$other->getBestName());
|
||||
$content = sprintf(_m('%s (%s) stopped following %s (%s).'),
|
||||
$content = sprintf(_m('%1$s (%2$s) stopped following %3$s (%4$s).'),
|
||||
$subscriber->getBestName(),
|
||||
$subscriber->profileurl,
|
||||
$other->getBestName(),
|
||||
@ -156,12 +155,12 @@ class ActivityPlugin extends Plugin
|
||||
$fave = Fave::pkeyGet(array('user_id' => $user->id,
|
||||
'notice_id' => $notice->id));
|
||||
|
||||
$rendered = sprintf(_m('<a href="%s">%s</a> liked <a href="%s">%s\'s update</a>.'),
|
||||
$rendered = sprintf(_m('<a href="%1$s">%2$s</a> liked <a href="%3$s">%4$s\'s update</a>.'),
|
||||
$profile->profileurl,
|
||||
$profile->getBestName(),
|
||||
$notice->bestUrl(),
|
||||
$author->getBestName());
|
||||
$content = sprintf(_m('%s (%s) liked %s\'s status (%s)'),
|
||||
$content = sprintf(_m('%1$s (%2$s) liked %3$s\'s status (%4$s)'),
|
||||
$profile->getBestName(),
|
||||
$profile->profileurl,
|
||||
$author->getBestName(),
|
||||
@ -189,12 +188,12 @@ class ActivityPlugin extends Plugin
|
||||
|
||||
if (!empty($user)) {
|
||||
$author = Profile::staticGet('id', $notice->profile_id);
|
||||
$rendered = sprintf(_m('<a href="%s">%s</a> stopped liking <a href="%s">%s\'s update</a>.'),
|
||||
$rendered = sprintf(_m('<a href="%1$s">%2$s</a> stopped liking <a href="%3$s">%4$s\'s update</a>.'),
|
||||
$profile->profileurl,
|
||||
$profile->getBestName(),
|
||||
$notice->bestUrl(),
|
||||
$author->getBestName());
|
||||
$content = sprintf(_m('%s (%s) stopped liking %s\'s status (%s)'),
|
||||
$content = sprintf(_m('%1$s (%2$s) stopped liking %3$s\'s status (%4$s)'),
|
||||
$profile->getBestName(),
|
||||
$profile->profileurl,
|
||||
$author->getBestName(),
|
||||
@ -230,12 +229,12 @@ class ActivityPlugin extends Plugin
|
||||
return true;
|
||||
}
|
||||
|
||||
$rendered = sprintf(_m('<a href="%s">%s</a> joined the group <a href="%s">%s</a>.'),
|
||||
$rendered = sprintf(_m('<a href="%1$s">%2$s</a> joined the group <a href="%3$s">%4$s</a>.'),
|
||||
$profile->profileurl,
|
||||
$profile->getBestName(),
|
||||
$group->homeUrl(),
|
||||
$group->getBestName());
|
||||
$content = sprintf(_m('%s (%s) joined the group %s (%s).'),
|
||||
$content = sprintf(_m('%1$s (%2$s) joined the group %3$s (%4$s).'),
|
||||
$profile->getBestName(),
|
||||
$profile->profileurl,
|
||||
$group->getBestName(),
|
||||
@ -267,12 +266,12 @@ class ActivityPlugin extends Plugin
|
||||
return true;
|
||||
}
|
||||
|
||||
$rendered = sprintf(_m('<a href="%s">%s</a> left the group <a href="%s">%s</a>.'),
|
||||
$rendered = sprintf(_m('<a href="%1$s">%2$s</a> left the group <a href="%3$s">%4$s</a>.'),
|
||||
$profile->profileurl,
|
||||
$profile->getBestName(),
|
||||
$group->homeUrl(),
|
||||
$group->getBestName());
|
||||
$content = sprintf(_m('%s (%s) left the group %s (%s)'),
|
||||
$content = sprintf(_m('%1$s (%2$s) left the group %3$s (%4$s)'),
|
||||
$profile->getBestName(),
|
||||
$profile->profileurl,
|
||||
$group->getBestName(),
|
||||
@ -387,6 +386,7 @@ class ActivityPlugin extends Plugin
|
||||
'author' => 'Evan Prodromou',
|
||||
'homepage' => 'http://status.net/wiki/Plugin:Activity',
|
||||
'rawdescription' =>
|
||||
// TRANS: Plugin description.
|
||||
_m('Emits notices when social activities happen.'));
|
||||
return true;
|
||||
}
|
||||
|
@ -44,8 +44,6 @@ if (!defined('STATUSNET')) {
|
||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class FollowListItem extends SystemListItem
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -44,7 +44,6 @@ if (!defined('STATUSNET')) {
|
||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class JoinListItem extends SystemListItem
|
||||
{
|
||||
function showContent()
|
||||
@ -58,7 +57,7 @@ class JoinListItem extends SystemListItem
|
||||
$out->elementStart('div', 'join-activity');
|
||||
$profile = $mem->getMember();
|
||||
$group = $mem->getGroup();
|
||||
$out->raw(sprintf(_m('<a href="%s">%s</a> joined the group <a href="%s">%s</a>.'),
|
||||
$out->raw(sprintf(_m('<a href="%1$s">%2$s</a> joined the group <a href="%3$s">%4$s</a>.'),
|
||||
$profile->profileurl,
|
||||
$profile->getBestName(),
|
||||
$group->homeUrl(),
|
||||
@ -70,4 +69,3 @@ class JoinListItem extends SystemListItem
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -44,8 +44,6 @@ if (!defined('STATUSNET')) {
|
||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class LeaveListItem extends SystemListItem
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -44,7 +44,6 @@ if (!defined('STATUSNET')) {
|
||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class SystemListItem extends NoticeListItemAdapter
|
||||
{
|
||||
/**
|
||||
@ -52,7 +51,6 @@ class SystemListItem extends NoticeListItemAdapter
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function showNotice()
|
||||
{
|
||||
$out = $this->nli->out;
|
||||
|
@ -44,7 +44,6 @@ if (!defined('STATUSNET')) {
|
||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class UnfollowListItem extends SystemListItem
|
||||
{
|
||||
/**
|
||||
@ -52,7 +51,6 @@ class UnfollowListItem extends SystemListItem
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function showNotice()
|
||||
{
|
||||
$out = $this->nli->out;
|
||||
@ -75,4 +73,3 @@ class UnfollowListItem extends SystemListItem
|
||||
$out->elementEnd('div');
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user