Use new EventPresentationModel::getViewingUserForGender() helper

Change-Id: I163a8f95ae055eeeac274657abefd7668e168f5f
This commit is contained in:
Kunal Mehta 2015-11-12 16:03:55 -08:00
parent 9a5a6dd4d7
commit a4fb2aab55
2 changed files with 2 additions and 4 deletions

View file

@ -13,8 +13,7 @@ class EchoFlowThanksPresentationModel extends EchoEventPresentationModel {
$msg->params( $this->event->getExtraParam( 'topic-title' ) ); $msg->params( $this->event->getExtraParam( 'topic-title' ) );
$msg->params( $this->event->getTitle()->getPrefixedText() ); $msg->params( $this->event->getTitle()->getPrefixedText() );
$user = User::newFromId( $this->event->getExtraParam( 'thanked-user-id' ) ); $msg->params( $this->getViewingUserForGender() );
$msg->params( $user ? $user->getName() : '[]' );
return $msg; return $msg;
} }

View file

@ -12,8 +12,7 @@ class EchoThanksPresentationModel extends EchoEventPresentationModel {
$msg = parent::getHeaderMessage(); $msg = parent::getHeaderMessage();
$msg->params( $this->event->getTitle()->getPrefixedText() ); $msg->params( $this->event->getTitle()->getPrefixedText() );
$user = User::newFromId( $this->event->getExtraParam( 'thanked-user-id' ) ); $msg->params( $this->getViewingUserForGender() );
$msg->params( $user ? $user->getName() : '[]' );
return $msg; return $msg;
} }