aboutsummaryrefslogtreecommitdiffhomepage
path: root/inc/poche
diff options
context:
space:
mode:
authortcitworld <tcit@tcit.fr>2014-09-10 20:05:07 +0200
committertcitworld <tcit@tcit.fr>2014-09-10 20:05:07 +0200
commit49882dc1517e84e33cea247f2e635691d1439904 (patch)
treef94547f60027c58bd7597086c2dcc231606b2c39 /inc/poche
parent19438d30215e59c8433d869b0ff23777c7bc3ab2 (diff)
parentd5c481c2f40f1d05750a7020df1f129439627247 (diff)
downloadwallabag-49882dc1517e84e33cea247f2e635691d1439904.tar.gz
wallabag-49882dc1517e84e33cea247f2e635691d1439904.tar.zst
wallabag-49882dc1517e84e33cea247f2e635691d1439904.zip
Merge pull request #819 from wallabag/fixSQLiteDownloadDB
Fix downloading SQLite database from all users
Diffstat (limited to 'inc/poche')
-rwxr-xr-xinc/poche/Routing.class.php2
-rwxr-xr-xinc/poche/Tools.class.php15
2 files changed, 0 insertions, 17 deletions
diff --git a/inc/poche/Routing.class.php b/inc/poche/Routing.class.php
index 004bd45a..0b373058 100755
--- a/inc/poche/Routing.class.php
+++ b/inc/poche/Routing.class.php
@@ -124,8 +124,6 @@ class Routing
124 } elseif (isset($_GET['import'])) { 124 } elseif (isset($_GET['import'])) {
125 $import = $this->wallabag->import(); 125 $import = $this->wallabag->import();
126 $tplVars = array_merge($this->vars, $import); 126 $tplVars = array_merge($this->vars, $import);
127 } elseif (isset($_GET['download'])) {
128 Tools::downloadDb();
129 } elseif (isset($_GET['empty-cache'])) { 127 } elseif (isset($_GET['empty-cache'])) {
130 Tools::emptyCache(); 128 Tools::emptyCache();
131 } elseif (isset($_GET['export'])) { 129 } elseif (isset($_GET['export'])) {
diff --git a/inc/poche/Tools.class.php b/inc/poche/Tools.class.php
index 63137d76..55fedac8 100755
--- a/inc/poche/Tools.class.php
+++ b/inc/poche/Tools.class.php
@@ -295,21 +295,6 @@ final class Tools
295 } 295 }
296 296
297 /** 297 /**
298 * Download the sqlite database
299 */
300 public static function downloadDb()
301 {
302 header('Content-Disposition: attachment; filename="poche.sqlite.gz"');
303 self::_status(200);
304
305 header('Content-Transfer-Encoding: binary');
306 header('Content-Type: application/octet-stream');
307 echo gzencode(file_get_contents(STORAGE_SQLITE));
308
309 exit;
310 }
311
312 /**
313 * Get the content for a given URL (by a call to FullTextFeed) 298 * Get the content for a given URL (by a call to FullTextFeed)
314 * 299 *
315 * @param Url $url 300 * @param Url $url