projects
/
quix0rs-gnu-social.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a838891
)
Set the current user on API calls
author
Evan Prodromou
<evan@status.net>
Wed, 25 May 2011 18:01:22 +0000
(14:01 -0400)
committer
Evan Prodromou
<evan@status.net>
Wed, 25 May 2011 18:01:22 +0000
(14:01 -0400)
lib/apiauth.php
patch
|
blob
|
history
diff --git
a/lib/apiauth.php
b/lib/apiauth.php
index 1e2a6101d66f801658d1c3e92133a3dca2b1fd24..1061e6b68c0b6a9d6c034d3b2e4604e1a26c3c6f 100644
(file)
--- a/
lib/apiauth.php
+++ b/
lib/apiauth.php
@@
-204,9
+204,12
@@
class ApiAuthAction extends ApiAction
}
}
$this->auth_user = $user;
+ // FIXME: setting the value returned by common_current_user()
+ // There should probably be a better method for this. common_set_user()
+ // does lots of session stuff.
global $_cur;
$_cur = $this->auth_user;
- Event::handle('EndSetApiUser', array($user));
+ Event::handle('EndSetApiUser', array($user));
}
$msg = "API OAuth authentication for user '%s' (id: %d) on behalf of " .