aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module
diff options
context:
space:
mode:
authorM.Dent <dentm42@dm42.net>2018-08-10 12:44:57 -0400
committerDM42.Net (Matt Dent) <dentm42@dm42.net>2018-08-10 13:54:07 -0400
commite587fe5ce84ed5c248287eb55c6ae193ebd3222b (patch)
tree29ad164f0c6d4aca069567dde48ee8ac6f0cc47a /Zotlabs/Module
parent48e74035f26ed8228ae834c633056fdc87668b71 (diff)
downloadvolse-hubzilla-e587fe5ce84ed5c248287eb55c6ae193ebd3222b.tar.gz
volse-hubzilla-e587fe5ce84ed5c248287eb55c6ae193ebd3222b.tar.bz2
volse-hubzilla-e587fe5ce84ed5c248287eb55c6ae193ebd3222b.zip
Add user_id = local_channel() to the where clause of updates
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r--Zotlabs/Module/Settings/Oauth2.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/Zotlabs/Module/Settings/Oauth2.php b/Zotlabs/Module/Settings/Oauth2.php
index 985095115..52da20598 100644
--- a/Zotlabs/Module/Settings/Oauth2.php
+++ b/Zotlabs/Module/Settings/Oauth2.php
@@ -45,14 +45,15 @@ class Oauth2 {
grant_types = '%s',
scope = '%s',
user_id = %d
- WHERE client_id='%s'",
+ WHERE client_id='%s' and user_id = %s",
dbesc($name),
dbesc($secret),
dbesc($redirect),
dbesc($grant),
dbesc($scope),
intval(local_channel()),
- dbesc($name));
+ dbesc($name),
+ intval(local_channel()));
} else {
$r = q("INSERT INTO oauth_clients (client_id, client_secret, redirect_uri, grant_types, scope, user_id)
VALUES ('%s','%s','%s','%s','%s',%d)",