Google Apps integration: ERROR: Incorrect number of query parameters. Expected 1, got 0

Google Apps integration: ERROR: Incorrect number of query parameters. Expected 1, got 0

by Kostis M -
Number of replies: 0

Hello Everyone,
I am trying to integrate moodle 2.6.4 and Google. I have followed each and every single 
step
But when I try to sync the users from Moodle User sync block I am getting error
ERROR: Incorrect number of query parameters. Expected 1, got 0.
Also i am getting the following errors from the debugging:

  • line ? of unknownfile: call to block_gdata::view()
  • line 1671 of /lib/blocklib.php: call to call_user_func()
  • line 35 of /blocks/gdata/index.php: call to block_method_result()
Invalid array parameter detected in required_param(): userids
  • line 637 of /lib/moodlelib.php: call to debugging()
  • line 432 of /blocks/gdata/block_gdata.php: call to optional_param()
  • line 272 of /blocks/gdata/block_gdata.php: call to block_gdata->addusers_process()
  • line ? of unknownfile: call to block_gdata::view()
  • line 1671 of /lib/blocklib.php: call to call_user_func()
  • line 35 of /blocks/gdata/index.php: call to block_method_result()
Aldo i have updated the line below from the file /blocks/gdata/block_gdata.php,:
if ($users = $DB->get_records_sql("$select $from $where ORDER BY ".$table->get_sql_sort(), array(), $table->get_page_start(), $table->get_page_size())) {
Change it to:
if ($users = $DB->get_records_sql("$select $from $where ORDER BY ".$table->get_sql_sort(), $params, $table->get_page_start(), $table->get_page_size())) {
Can someone help me?
Kind Regards
Kostis
Average of ratings: -