diff options
| author | Bharat Mediratta <bharat@menalto.com> | 2009-12-02 19:08:13 -0800 | 
|---|---|---|
| committer | Bharat Mediratta <bharat@menalto.com> | 2009-12-02 19:08:13 -0800 | 
| commit | c9e6869c681fa6579d1858cea45ec94eb0972f30 (patch) | |
| tree | 24853f8df9cadabbd10efebc64ad2f27db489148 /modules/gallery/helpers/gallery_installer.php | |
| parent | 1ab8ac305bf53bae8c05b917b06f035b9b700937 (diff) | |
Rename the "upload_limit" variable to "simultaneous_upload_limit" for
clarity, since it only limits concurrency not the number of actual uploads.
Move the default-setting code into the upgrader so that we avoid
creating the variable as a side-effect of the view (personal
preference to avoid side-effect code since it's led to problems in the
past).
Diffstat (limited to 'modules/gallery/helpers/gallery_installer.php')
| -rw-r--r-- | modules/gallery/helpers/gallery_installer.php | 7 | 
1 files changed, 7 insertions, 0 deletions
diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php index 57a5ee9f..39859b36 100644 --- a/modules/gallery/helpers/gallery_installer.php +++ b/modules/gallery/helpers/gallery_installer.php @@ -432,6 +432,13 @@ class gallery_installer {        module::clear_var("gallery", "blocks_site.sidebar");        module::set_version("gallery", $version = 19);      } + +    // Set a default for the number of simultaneous uploads +    // Version 20 was reverted in 57adefc5baa7a2b0dfcd3e736e80c2fa86d3bfa2, so skip it. +    if ($version == 19 || $version == 20) { +      module::set_var("gallery", "simultaneous_upload_limit", 5); +      module::set_version("gallery", $version = 21); +    }    }    static function uninstall() {  | 
