summaryrefslogtreecommitdiff
path: root/modules/rest
diff options
context:
space:
mode:
Diffstat (limited to 'modules/rest')
-rw-r--r--modules/rest/helpers/rest.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/rest/helpers/rest.php b/modules/rest/helpers/rest.php
index 0bad58f6..bcb12d58 100644
--- a/modules/rest/helpers/rest.php
+++ b/modules/rest/helpers/rest.php
@@ -72,7 +72,7 @@ class rest_Core {
->find();
if (!$key->loaded()) {
- $key->user_id = $user_id;
+ $key->user_id = identity::active_user()->id;
$key->access_key = md5(md5(uniqid(mt_rand(), true) . access::private_key()));
$key->save();
}