summaryrefslogtreecommitdiffstats
path: root/apps/files_versions/ajax
diff options
context:
space:
mode:
authorSam Tuke <samtuke@owncloud.com>2012-07-03 17:42:51 +0100
committerSam Tuke <samtuke@owncloud.com>2012-07-03 17:42:51 +0100
commita775deaf22ee803ae2ff0dbe1068229d9c819232 (patch)
treef7a7f5ee4d57935710903ab649f53ee948108fad /apps/files_versions/ajax
parentca2b1f78630257ff4a2beadb5e25d628e5195bb0 (diff)
downloadnextcloud-server-a775deaf22ee803ae2ff0dbe1068229d9c819232.tar.gz
nextcloud-server-a775deaf22ee803ae2ff0dbe1068229d9c819232.zip
Moved hooks and versions.php into new lib directory
Part-ported filesystem operations to OC_FilesystemView Refactored Storage class to depend on an OC_FsV object and have fewer static classes
Diffstat (limited to 'apps/files_versions/ajax')
-rw-r--r--apps/files_versions/ajax/expireAll.php4
-rw-r--r--apps/files_versions/ajax/getVersions.php2
2 files changed, 3 insertions, 3 deletions
diff --git a/apps/files_versions/ajax/expireAll.php b/apps/files_versions/ajax/expireAll.php
index f9cd74aed02..238e3bdad4d 100644
--- a/apps/files_versions/ajax/expireAll.php
+++ b/apps/files_versions/ajax/expireAll.php
@@ -28,7 +28,9 @@
OCP\JSON::checkLoggedIn();
OCP\App::checkAppEnabled('files_versions');
-if( OCA_Versions\Storage::expireAll() ){
+$versions = new OCA_Versions\Storage( new OC_FilesystemView('') );
+
+if( $versions->expireAll() ){
OCP\JSON::success();
die();
diff --git a/apps/files_versions/ajax/getVersions.php b/apps/files_versions/ajax/getVersions.php
index f29d1760b6f..1a0e21732cc 100644
--- a/apps/files_versions/ajax/getVersions.php
+++ b/apps/files_versions/ajax/getVersions.php
@@ -1,8 +1,6 @@
<?php
OCP\JSON::checkAppEnabled('files_versions');
-require_once('apps/files_versions/versions.php');
-
$userDirectory = "/".OCP\USER::getUser()."/files";
$source = $_GET['source'];