moodlelib: require_login() rework
commit21e2dcd946f9e89a2c410ca1c0bdd91d567efa40
authormartinlanghoff <martinlanghoff>
Wed, 19 Sep 2007 07:25:49 +0000 (19 07:25 +0000)
committermartinlanghoff <martinlanghoff>
Wed, 19 Sep 2007 07:25:49 +0000 (19 07:25 +0000)
tree134233c9a744e06d15cdb250afb76ee1df75c43d
parent3c2dbf376eb7b4c88ef7e739a0ac475ce75ad939
moodlelib: require_login() rework

A bit of rework around require_login()

 - Fixed a subtle bug in the check whether a user can see sitecourse
   hidden activities

 - Save 1 DBq and 2 includes per call by only calling
   get_auth_plugin() only when needed.

 - Grab the contexts we are interested in only once and keep them in
   variables.
lib/moodlelib.php