/**
* Prepares an update message for an existing showcase discussion thread
*
* @param array $item
* @param array $thread
*
* @return string
*/
public function prepareUpdateMessageForPostToThread(array $item, array $thread, $customMessage)
{
if ($customMessage)
{
$snippet = $customMessage;
}
else
{
$snip = XenForo_Application::get('options')->scMaxMessageSnippetLength;
$snippet = trim(XenForo_Helper_String::wholeWordTrim($item['message'], $snip));
}
$message = new XenForo_Phrase('nflj_showcase_message_update_item', array(
'title' => $item['item_name'],
'username' => $item['username'],
'userId' => $item['user_id'],
'snippet' => $snippet,
'itemLink' => XenForo_Link::buildPublicLink('canonical:showcase', $item)
), false);
return $message;
}