Permalink
Browse files

MDL-34368: Fix broken query in so tokens are correctly checked agains…

…t the linked service
  • Loading branch information...
1 parent 7a9aacf commit 20c116f9f753553c3a5badac8c4764d41461d4ff Nathan Mares committed with danpoltawski Jul 17, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 webservice/lib.php
View
@@ -979,7 +979,7 @@ protected function init_service_class() {
FROM {external_services} s
JOIN {external_services_functions} sf ON (sf.externalserviceid = s.id AND s.restrictedusers = 1)
JOIN {external_services_users} su ON (su.externalserviceid = s.id AND su.userid = :userid)
- WHERE s.enabled = 1 AND su.validuntil IS NULL OR su.validuntil < :now $wscond2";
+ WHERE s.enabled = 1 AND (su.validuntil IS NULL OR su.validuntil < :now) $wscond2";
$params = array_merge($params, array('userid'=>$USER->id, 'now'=>time()));

0 comments on commit 20c116f

Please sign in to comment.