summaryrefslogtreecommitdiffstats
path: root/lib.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib.php')
-rw-r--r--lib.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib.php b/lib.php
index 2fec295..94186a7 100644
--- a/lib.php
+++ b/lib.php
@@ -28,6 +28,7 @@
*/
function get_submitted_packages($upload_dir, $max_modified)
{
+ $cwd = getcwd();
chdir($upload_dir);
$matches = array();
@@ -38,6 +39,8 @@ function get_submitted_packages($upload_dir, $max_modified)
$matches,
PREG_SET_ORDER);
+ chdir($cwd);
+
return $matches;
}