public function isUnread($userId)
    {
        try {
            $participant = $this->getParticipantFromUser($userId);
            if ($this->updated_at > $participant->last_read) {
                return true;
            }
        } catch (ModelNotFoundException $e) {
            // do nothing
        }

        return false;
    }
public function isUnread($userId)
    {
        try {
            $participant = $this->getParticipantFromUser($userId);
            if ($this->updated_at > $participant->last_read) {
                return true;
            }
        } catch (ModelNotFoundException $e) {
            // do nothing
        }

        return false;
    }
public function isUnread ( $ userId ) { try { $ participant = $ this -> getParticipantFromUser ( $ userId ) ; if ( $ this -> updated_at > $ participant -> last_read ) { return true ; } } catch ( ModelNotFoundException $ e ) { // do nothing } return false ; }
See if the current thread is unread by the user

@param integer $userId
@return bool
See if the current thread is unread by the user