Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Trivial
-
Resolution: Fixed
-
Affects Version/s: 1.4.1
-
Component/s: Administration
-
Labels:None
-
Environment:All
-
Affected Branches:MOODLE_14_STABLE
-
Fixed Branches:MOODLE_18_STABLE, MOODLE_19_STABLE
Description
The scales.php script checks all the site wide custom scales against every course in the database to check if its used. This really slows down the page.
This checking is not necessary unless the person accessing the scales.php page is the administrator, since it is only the administrator who can edit site wide scales.
The version i am using is Moodle 1.4 development (2004070800)
From Girishan Shanmugam (girishan at tamu.edu) Friday, 3 September 2004, 11:49 PM:
I made this quick change that makes the page faster for non admins in the /course/scales.php script.
439,444c439
< //A change to speed up the scales pages for non admins
< //September 3rd 2004. Girishan Shanmugam
< if(isadmin()){ < $scales_uses = site_scale_used($scale->id); < }
< //End of change.
—
> $scales_uses = site_scale_used($scale->id);
From Girishan Shanmugam (girishan at tamu.edu) Saturday, 4 September 2004, 12:17 AM:
I took the diff the wrong way. This should make more sense. (not yet familiar with diff/patch)
File: /course/scales.php
439c439,444
< $scales_uses = site_scale_used($scale->id);
—
> //A change to speed up the scales pages for non admins
> //September 3rd 2004. Girishan Shanmugam
> if(isadmin()){ > $scales_uses = site_scale_used($scale->id); > }
> //End of change.
From Martin Langhoff (martin at catalyst.net.nz) Monday, 13 December 2004, 04:13 PM:
girishan, 1.4.2+ contain some performance improvements to the scales area. Can you give it a try and report back?