]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/jabber.php
Correction to previous commit
[quix0rs-gnu-social.git] / lib / jabber.php
index 3dcdce5dbf349b87b629e9186bcb98ef519d22a9..a821856a8b004c92e1b00879bbf15eba3fd5228c 100644 (file)
@@ -184,6 +184,11 @@ function jabber_format_entry($profile, $notice)
     } else {
         $xs->raw(common_render_content($notice->content, $notice));
     }
+    $xs->text(" ");
+    $xs->element('a', array(
+        'href'=>common_local_url('conversation',
+            array('id' => $notice->conversation)).'#notice-'.$notice->id
+         ),sprintf(_('[%s]'),$notice->id));
     $xs->elementEnd('body');
     $xs->elementEnd('html');
 
@@ -435,7 +440,7 @@ function jabber_public_notice($notice)
     // XXX: should we send out non-local messages if public,localonly
     // = false? I think not
 
-    if ($public && $notice->is_local) {
+    if ($public && $notice->is_local == Notice::LOCAL_PUBLIC) {
         $profile = Profile::staticGet($notice->profile_id);
 
         if (!$profile) {
@@ -475,5 +480,5 @@ function jabber_public_notice($notice)
 
 function jabber_format_notice(&$profile, &$notice)
 {
-    return $profile->nickname . ': ' . $notice->content;
+    return $profile->nickname . ': ' . $notice->content . ' [' . $notice->id . ']';
 }