aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-07-21 13:22:58 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-07-21 13:22:58 +0000
commit19f33bc9ebc93f326e9aa31581327e48217757d6 (patch)
treeb39963e6f6264506cb23ba67d886c5ff24f04d4e /engine
parentb18528c088de050bfcd9baadc35be99cec9122c1 (diff)
downloadelgg-19f33bc9ebc93f326e9aa31581327e48217757d6.tar.gz
elgg-19f33bc9ebc93f326e9aa31581327e48217757d6.tar.bz2
Merged pervious commit to 1.8.
git-svn-id: http://code.elgg.org/elgg/trunk@6754 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/actions.php12
1 files changed, 9 insertions, 3 deletions
diff --git a/engine/lib/actions.php b/engine/lib/actions.php
index 57da1389f..b715577a9 100644
--- a/engine/lib/actions.php
+++ b/engine/lib/actions.php
@@ -124,9 +124,15 @@ function actions_init($event, $object_type, $object) {
*
* @return unknown
*/
-function validate_action_token($visibleerrors = true) {
- $token = get_input('__elgg_token');
- $ts = get_input('__elgg_ts');
+function validate_action_token($visibleerrors = TRUE, $token = NULL, $ts = NULL) {
+ if (!$token) {
+ $token = get_input('__elgg_token');
+ }
+
+ if (!$ts) {
+ $ts = get_input('__elgg_ts');
+ }
+
$session_id = session_id();
if (($token) && ($ts) && ($session_id)) {