Call to a member function on a non-object

Call to a member function on a non-object

Daniele Cordella發表於
Number of replies: 4
Core developers的相片 Plugin developers的相片
Hei developers
upgrading to the just downloaded daily release of Moodle 1.9
I got the error shown at the end of this post.
Was this error already known, already fixed, already announced (I believe I read something from MD but I no longer can find what I read) or has to be added to the tracker?
Thank you in advance.


 <div class="notifytiny" style="text-align:center">You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')
 AND (ctx.id= OR ctx.path LIKE '/%'))
 <br /><br />SELECT ctx.path, rc.roleid, rc.capability, rc.permission
 FROM m19_role_capabilities rc
 JOIN m19_context ctx
 ON rc.contextid=ctx.id
 WHERE (rc.roleid IN ()
 AND (ctx.id= OR ctx.path LIKE '/%'))

 ORDER BY ctx.depth ASC, ctx.path DESC, rc.roleid ASC <ul style="text-align: left">
<li>line 677 of lib/dmllib.php: call to debugging()</li><li>line 1409 of lib/accesslib.php: call to get_recordset_sql()</li>
<li>line 401 of lib/accesslib.php: call to get_user_access_bycontext()</li>
<li>line 696 of blocks/moodleblock.class.php: call to has_capability()</li>
<li>line 240 of lib/blocklib.php: call to block_site_main_menu-&gt;is_empty()</li>
<li>line 128 of index.php: call to blocks_have_content()</li></ul></div>
<br />
<b>Fatal error</b>: Call to a member function on a non-object in <b>/Users/daniele/Sites/moodle19/lib/accesslib.php</b> on line <b>1411</b><br />

評比平均分數: -
In reply to Daniele Cordella

Re: Call to a member function on a non-object

Martin Dougiamas發表於
Core developers的相片 Documentation writers的相片 Moodle HQ的相片 Particularly helpful Moodlers的相片 Plugin developers的相片 Testers的相片
Should all be fixed in latest CVS (make sure you visit the admin page after update)
In reply to Martin Dougiamas

Re: Call to a member function on a non-object

Daniele Cordella發表於
Core developers的相片 Plugin developers的相片
How can I do it?
Nothing is available.
附件 Immagine2.png
In reply to Daniele Cordella

Re: Call to a member function on a non-object

Tim Hunt發表於
Core developers的相片 Documentation writers的相片 Particularly helpful Moodlers的相片 Peer reviewers的相片 Plugin developers的相片
Type the URL http://example.com/moodle/admin/index.php directly into your browser.