X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=plugins%2FXmpp%2FXmppPlugin.php;h=7112b8b63eaeb8013bf24be41ff05047ab8b1b33;hb=d6b28c64830f632bb2f4b6f3c9369b9e56ad217a;hp=002055309d7e7090072b2ef277d1696aa966e416;hpb=c909f351d07c50c433cd59fef00f41a67767ce9e;p=quix0rs-gnu-social.git diff --git a/plugins/Xmpp/XmppPlugin.php b/plugins/Xmpp/XmppPlugin.php index 002055309d..7112b8b63e 100644 --- a/plugins/Xmpp/XmppPlugin.php +++ b/plugins/Xmpp/XmppPlugin.php @@ -308,11 +308,6 @@ class XmppPlugin extends ImPlugin return true; } - function microiduri($screenname) - { - return 'xmpp:' . $screenname; - } - function sendMessage($screenname, $body) { $this->queuedConnection()->message($screenname, $body, 'chat'); @@ -354,15 +349,14 @@ class XmppPlugin extends ImPlugin $xs->text(": "); } catch (InvalidUrlException $e) { $xs->text(sprintf(' => %s', $orig_profile->nickname)); - } catch (Exception $e) { + } catch (NoParentNoticeException $e) { + $xs->text(": "); + } catch (NoResultException $e) { + // Parent notice was probably deleted. $xs->text(": "); } - if (!empty($notice->rendered)) { - $notice->rendered = str_replace("\t", "", $notice->rendered); - $xs->raw($notice->rendered); - } else { - $xs->raw(common_render_content($notice->content, $notice)); - } + // FIXME: Why do we replace \t with ''? is it just to make it pretty? shouldn't whitespace be handled well...? + $xs->raw(str_replace("\t", "", $notice->getRendered())); $xs->text(" "); $xs->element('a', array( 'href'=>common_local_url('conversation',