diff options
author | Simon L'nu <simon.lnu@gmail.com> | 2012-05-31 23:22:19 -0400 |
---|---|---|
committer | Simon L'nu <simon.lnu@gmail.com> | 2012-05-31 23:22:19 -0400 |
commit | b1dacd6d838ecf75fe828279e57c2e7a866be22f (patch) | |
tree | 46b41c1f463ab90588f109105c95e85dad8fd432 /mod/dfrn_notify.php | |
parent | 04119d31e51c749cfa81b9a8ac5f52005d71f8c4 (diff) | |
parent | 93bc29a711637c84a4ffc380078277de89af4e6d (diff) | |
download | volse-hubzilla-b1dacd6d838ecf75fe828279e57c2e7a866be22f.tar.gz volse-hubzilla-b1dacd6d838ecf75fe828279e57c2e7a866be22f.tar.bz2 volse-hubzilla-b1dacd6d838ecf75fe828279e57c2e7a866be22f.zip |
Merge branch 'master', remote-tracking branch 'remotes/upstream/master'
* remotes/upstream/master:
turn registration code into a standalone function for re-use
query using both `id` and `parent`
prevent email from leaking in feeds
y didn't i think of this b4?
some zero theming on settings page
missing delimiter
transition to beta for private forums
rev update
Friendicaland - you can't 'live' on a demo server.
Create a "potential default group" called "Friends" on registration.
fix private photos that also have a size specification
private group tests, cont.
hide private group if desired
prvgroup should see intros
private group fix
possible sql injection in search
bugfixes: private photo embeds and search for strings with %
* master:
Diffstat (limited to 'mod/dfrn_notify.php')
-rw-r--r-- | mod/dfrn_notify.php | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/mod/dfrn_notify.php b/mod/dfrn_notify.php index 65d39d5fe..e55da5572 100644 --- a/mod/dfrn_notify.php +++ b/mod/dfrn_notify.php @@ -17,6 +17,9 @@ function dfrn_notify_post(&$a) { $ssl_policy = ((x($_POST,'ssl_policy')) ? notags(trim($_POST['ssl_policy'])): 'none'); $page = ((x($_POST,'page')) ? intval($_POST['page']) : 0); + $forum = (($page == 1) ? 1 : 0); + $prv = (($page == 2) ? 1 : 0); + $writable = (-1); if($dfrn_version >= 2.21) { $writable = (($perm === 'rw') ? 1 : 0); @@ -88,10 +91,11 @@ function dfrn_notify_post(&$a) { $importer = $r[0]; - if((($writable != (-1)) && ($writable != $importer['writable'])) || ($importer['forum'] != $page)) { - q("UPDATE `contact` SET `writable` = %d, forum = %d WHERE `id` = %d LIMIT 1", + if((($writable != (-1)) && ($writable != $importer['writable'])) || ($importer['forum'] != $forum) || ($importer['prv'] != $prv)) { + q("UPDATE `contact` SET `writable` = %d, forum = %d, prv = %d WHERE `id` = %d LIMIT 1", intval(($writable == (-1)) ? $importer['writable'] : $writable), - intval($page), + intval($forum), + intval($prv), intval($importer['id']) ); if($writable != (-1)) |