Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAleksey Lim <alsroot@member.fsf.org>2009-08-19 15:08:44 (GMT)
committer Aleksey Lim <alsroot@member.fsf.org>2009-08-19 15:08:44 (GMT)
commitf4676e6da4c967511bd27560301f56f66e1e37ed (patch)
tree94507b14a3a444b7bb8f7b336572167e1142c37c
parentc147a3e84c17ef55e3dd300cadb4a7da81f4c5db (diff)
Force rederection for files downloads
-rw-r--r--aslo/config.php2
-rw-r--r--site/app/controllers/downloads_controller.php7
-rw-r--r--site/app/webroot/services/update.php2
3 files changed, 2 insertions, 9 deletions
diff --git a/aslo/config.php b/aslo/config.php
index 9c94429..452baae 100644
--- a/aslo/config.php
+++ b/aslo/config.php
@@ -90,7 +90,7 @@ define('SITE_STATE', 'dev');
* Host, including http://. Should be everything leading up to addon ids.
* Example: http://releases.mozilla.org/addons
*/
-define('FILES_HOST', 'http://activities.sugarlabs.org');
+define('FILES_HOST', 'http://download.sugarlabs.org/sources/activities');
/**
* Relative web path of the files directory. Tacking this on to FILES_HOST should get you
diff --git a/site/app/controllers/downloads_controller.php b/site/app/controllers/downloads_controller.php
index 0057a4d..edbdc66 100644
--- a/site/app/controllers/downloads_controller.php
+++ b/site/app/controllers/downloads_controller.php
@@ -103,15 +103,8 @@ class DownloadsController extends AppController
return;
}
- // force local delivery for non-browser apps
- global $browser_apps;
- if (!in_array(APP_ID, $browser_apps) || $type == 'attachment') {
- $forceLocal = true;
- $this->set('attachment', true);
- } else {
$forceLocal = false;
$this->set('attachment', false);
- }
$this->set('fileName', $file_data['File']['filename']);
diff --git a/site/app/webroot/services/update.php b/site/app/webroot/services/update.php
index 9371fb3..2acf767 100644
--- a/site/app/webroot/services/update.php
+++ b/site/app/webroot/services/update.php
@@ -258,7 +258,7 @@ if (empty($errors) && !$detect_installed) {
*
* If you want to test updates, change your config and set up a web dir with public files in it.
*/
- $data['uri'] = FILES_HOST.'/downloads/file/'.$data['file_id'].'/'.$data['filename'];
+ $data['uri'] = FILES_HOST . '/' . $data['id'] . '/' . $data['filename'];
}
if (!empty($data['type'])) {