aboutsummaryrefslogtreecommitdiffstats
path: root/include/message.php
diff options
context:
space:
mode:
authorHaakon Meland Eriksen <haakon.eriksen@far.no>2015-08-19 19:40:18 +0200
committerHaakon Meland Eriksen <haakon.eriksen@far.no>2015-08-19 19:40:18 +0200
commite50e68719155c7d35e30bb203a403854f789d5a1 (patch)
treea10630cec177c6629fb0da38d96deb7258062698 /include/message.php
parent07cd0c870f48ec838c23fa7c6966ceb1c41f06ab (diff)
parent4e3d295c909405da61d7ccd6c7bd99bd35c9feec (diff)
downloadvolse-hubzilla-e50e68719155c7d35e30bb203a403854f789d5a1.tar.gz
volse-hubzilla-e50e68719155c7d35e30bb203a403854f789d5a1.tar.bz2
volse-hubzilla-e50e68719155c7d35e30bb203a403854f789d5a1.zip
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'include/message.php')
-rw-r--r--include/message.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/message.php b/include/message.php
index 46f113cf4..5720d2da4 100644
--- a/include/message.php
+++ b/include/message.php
@@ -170,11 +170,11 @@ function send_message($uid = 0, $recipient='', $body='', $subject='', $replyto='
- $r = q("INSERT INTO mail ( account_id, convid, mail_flags, channel_id, from_xchan, to_xchan, title, body, attach, mid, parent_mid, created, expires )
+ $r = q("INSERT INTO mail ( account_id, convid, mail_obscured, channel_id, from_xchan, to_xchan, title, body, attach, mid, parent_mid, created, expires )
VALUES ( %d, %d, %d, %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' )",
intval($channel['channel_account_id']),
intval($convid),
- intval(MAIL_OBSCURED),
+ intval(1),
intval($channel['channel_id']),
dbesc($channel['channel_hash']),
dbesc($recipient),
@@ -330,6 +330,7 @@ function private_messages_fetch_message($channel_id, $messageitem_id, $updatesee
}
}
+
if($updateseen) {
$r = q("UPDATE `mail` SET mail_seen = 1 where mail_seen = 0 and id = %d AND channel_id = %d",
dbesc($messageitem_id),
@@ -416,6 +417,7 @@ function private_messages_fetch_conversation($channel_id, $messageitem_id, $upda
}
+
if($updateseen) {
$r = q("UPDATE `mail` SET mail_seen = 1 where mail_seen = 0 and parent_mid = '%s' AND channel_id = %d",
dbesc($r[0]['parent_mid']),