aboutsummaryrefslogtreecommitdiffstats
path: root/mod/mail.php
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2015-10-02 22:53:51 +0200
committerMario Vavti <mario@mariovavti.com>2015-10-02 22:53:51 +0200
commitd337cc6618889d031c920985fc3e05ed1b1e5f89 (patch)
treec477aaf7603e0850b653ae709db5c79ddcd199bd /mod/mail.php
parent3a8bff228e30abe243d0b28678af8dd6fc59a39b (diff)
downloadvolse-hubzilla-d337cc6618889d031c920985fc3e05ed1b1e5f89.tar.gz
volse-hubzilla-d337cc6618889d031c920985fc3e05ed1b1e5f89.tar.bz2
volse-hubzilla-d337cc6618889d031c920985fc3e05ed1b1e5f89.zip
private mail: $preid should be abook_xchan not abook_id
Diffstat (limited to 'mod/mail.php')
-rw-r--r--mod/mail.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/mod/mail.php b/mod/mail.php
index 54663b3ae..0f905f1da 100644
--- a/mod/mail.php
+++ b/mod/mail.php
@@ -185,20 +185,20 @@ function mail_content(&$a) {
$a->page['htmlhead'] .= $header;
-
$preselect = (isset($a->argv[2])?array($a->argv[2]):false);
$prename = $preurl = $preid = '';
-
+
if(x($_REQUEST,'hash')) {
$r = q("select abook.*, xchan.* from abook left join xchan on abook_xchan = xchan_hash
where abook_channel = %d and abook_xchan = '%s' limit 1",
intval(local_channel()),
dbesc($_REQUEST['hash'])
);
+
if($r) {
$prename = $r[0]['xchan_name'];
$preurl = $r[0]['xchan_url'];
- $preid = $r[0]['abook_id'];
+ $preid = $r[0]['abook_xchan'];
$preselect = array($preid);
}
}
@@ -213,7 +213,7 @@ function mail_content(&$a) {
if($r) {
$prename = $r[0]['xchan_name'];
$preurl = $r[0]['xchan_url'];
- $preid = $r[0]['abook_id'];
+ $preid = $r[0]['abook_xchan'];
}
}