aboutsummaryrefslogtreecommitdiffstats
path: root/include/oauth.php
diff options
context:
space:
mode:
authorHabeas Codice <habeascodice@federated.social>2015-05-24 09:26:12 -0700
committerHabeas Codice <habeascodice@federated.social>2015-05-24 09:26:12 -0700
commitb15a68f05db382d23b749428a04fe39cc6c156ad (patch)
tree19e84175f1c4782da860ad99f52855fc4c8fbaf0 /include/oauth.php
parent57d520e69fcb34a69f8e94038a23c8d52251bfc5 (diff)
downloadvolse-hubzilla-b15a68f05db382d23b749428a04fe39cc6c156ad.tar.gz
volse-hubzilla-b15a68f05db382d23b749428a04fe39cc6c156ad.tar.bz2
volse-hubzilla-b15a68f05db382d23b749428a04fe39cc6c156ad.zip
avoid db compatibility issues
Diffstat (limited to 'include/oauth.php')
-rw-r--r--include/oauth.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/oauth.php b/include/oauth.php
index ec754db95..8634f9c8a 100644
--- a/include/oauth.php
+++ b/include/oauth.php
@@ -75,12 +75,12 @@ class FKOAuthDataStore extends OAuthDataStore {
$k = $consumer;
}
- $r = q("INSERT INTO tokens (id, secret, client_id, scope, expires) VALUES ('%s','%s','%s','%s', UNIX_TIMESTAMP()+%d)",
+ $r = q("INSERT INTO tokens (id, secret, client_id, scope, expires) VALUES ('%s','%s','%s','%s', %d)",
dbesc($key),
dbesc($sec),
dbesc($k),
'request',
- intval(REQUEST_TOKEN_DURATION));
+ time()+intval(REQUEST_TOKEN_DURATION));
if (!$r) return null;
return new OAuthToken($key,$sec);