Skip to content
Snippets Groups Projects
Commit 4fe90f62 authored by Frank Karlitschek's avatar Frank Karlitschek
Browse files

port checkAppEnabled

parent eec7c383
No related branches found
No related tags found
No related merge requests found
Showing
with 20 additions and 20 deletions
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
* *
*/ */
OCP\User::checkAdminUser(); OCP\User::checkAdminUser();
OC_Util::checkAppEnabled('admin_migrate'); OCP\App::checkAppEnabled('admin_migrate');
// Export? // Export?
if (isset($_POST['admin_export'])) { if (isset($_POST['admin_export'])) {
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
// Check if we are a user // Check if we are a user
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('bookmarks'); OCP\App::checkAppEnabled('bookmarks');
require_once('bookmarksHelper.php'); require_once('bookmarksHelper.php');
addBookmark($_GET['url'], '', 'Read-Later'); addBookmark($_GET['url'], '', 'Read-Later');
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
// Check if we are a user // Check if we are a user
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('bookmarks'); OCP\App::checkAppEnabled('bookmarks');
OCP\App::setActiveNavigationEntry( 'bookmarks_index' ); OCP\App::setActiveNavigationEntry( 'bookmarks_index' );
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
OC_JSON::checkLoggedIn(); OC_JSON::checkLoggedIn();
OC_Util::checkAppEnabled('calendar'); OCP\App::checkAppEnabled('calendar');
$tmpl = new OC_Template('calendar', 'part.import'); $tmpl = new OC_Template('calendar', 'part.import');
$tmpl->assign('path', $_POST['path']); $tmpl->assign('path', $_POST['path']);
$tmpl->assign('filename', $_POST['filename']); $tmpl->assign('filename', $_POST['filename']);
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
//check for calendar rights or create new one //check for calendar rights or create new one
ob_start(); ob_start();
OC_JSON::checkLoggedIn(); OC_JSON::checkLoggedIn();
OC_Util::checkAppEnabled('calendar'); OCP\App::checkAppEnabled('calendar');
$nl="\r\n"; $nl="\r\n";
$comps = array('VEVENT'=>true, 'VTODO'=>true, 'VJOURNAL'=>true); $comps = array('VEVENT'=>true, 'VTODO'=>true, 'VJOURNAL'=>true);
$progressfile = 'import_tmp/' . md5(session_id()) . '.txt'; $progressfile = 'import_tmp/' . md5(session_id()) . '.txt';
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
$RUNTIME_NOSETUPFS = true; $RUNTIME_NOSETUPFS = true;
require_once('../lib/base.php'); require_once('../lib/base.php');
OC_Util::checkAppEnabled('calendar'); OCP\App::checkAppEnabled('calendar');
// Backends // Backends
$authBackend = new OC_Connector_Sabre_Auth(); $authBackend = new OC_Connector_Sabre_Auth();
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('calendar'); OCP\App::checkAppEnabled('calendar');
$cal = isset($_GET['calid']) ? $_GET['calid'] : NULL; $cal = isset($_GET['calid']) ? $_GET['calid'] : NULL;
$event = isset($_GET['eventid']) ? $_GET['eventid'] : NULL; $event = isset($_GET['eventid']) ? $_GET['eventid'] : NULL;
$nl = "\r\n"; $nl = "\r\n";
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('calendar'); OCP\App::checkAppEnabled('calendar');
// Create default calendar ... // Create default calendar ...
$calendars = OC_Calendar_Calendar::allCalendars(OCP\USER::getUser(), 1); $calendars = OC_Calendar_Calendar::allCalendars(OCP\USER::getUser(), 1);
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
require_once('../../../lib/base.php'); require_once('../../../lib/base.php');
OC_JSON::checkLoggedIn(); OC_JSON::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
$upload_max_filesize = OCP\Util::computerFileSize(ini_get('upload_max_filesize')); $upload_max_filesize = OCP\Util::computerFileSize(ini_get('upload_max_filesize'));
$post_max_size = OCP\Util::computerFileSize(ini_get('post_max_size')); $post_max_size = OCP\Util::computerFileSize(ini_get('post_max_size'));
$maxUploadFilesize = min($upload_max_filesize, $post_max_size); $maxUploadFilesize = min($upload_max_filesize, $post_max_size);
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
OC_JSON::checkLoggedIn(); OC_JSON::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
$tmpl = new OC_Template('contacts', 'part.import'); $tmpl = new OC_Template('contacts', 'part.import');
$tmpl->assign('path', $_POST['path']); $tmpl->assign('path', $_POST['path']);
$tmpl->assign('filename', $_POST['filename']); $tmpl->assign('filename', $_POST['filename']);
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
$RUNTIME_NOSETUPFS = true; $RUNTIME_NOSETUPFS = true;
require_once('../lib/base.php'); require_once('../lib/base.php');
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
// Backends // Backends
$authBackend = new OC_Connector_Sabre_Auth(); $authBackend = new OC_Connector_Sabre_Auth();
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
$bookid = isset($_GET['bookid']) ? $_GET['bookid'] : NULL; $bookid = isset($_GET['bookid']) ? $_GET['bookid'] : NULL;
$contactid = isset($_GET['contactid']) ? $_GET['contactid'] : NULL; $contactid = isset($_GET['contactid']) ? $_GET['contactid'] : NULL;
$nl = "\n"; $nl = "\n";
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
ob_start(); ob_start();
OC_JSON::checkLoggedIn(); OC_JSON::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
$nl = "\n"; $nl = "\n";
$progressfile = 'import_tmp/' . md5(session_id()) . '.txt'; $progressfile = 'import_tmp/' . md5(session_id()) . '.txt';
if(is_writable('import_tmp/')){ if(is_writable('import_tmp/')){
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
// Check if we are a user // Check if we are a user
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
// Get active address books. This creates a default one if none exists. // Get active address books. This creates a default one if none exists.
$ids = OC_Contacts_Addressbook::activeIds(OCP\USER::getUser()); $ids = OC_Contacts_Addressbook::activeIds(OCP\USER::getUser());
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
// Init owncloud // Init owncloud
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
function getStandardImage(){ function getStandardImage(){
OC_Response::setExpiresHeader('P10D'); OC_Response::setExpiresHeader('P10D');
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
OC_JSON::checkLoggedIn(); OC_JSON::checkLoggedIn();
//OCP\User::checkLoggedIn(); //OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('contacts'); OCP\App::checkAppEnabled('contacts');
function getStandardImage(){ function getStandardImage(){
OC_Response::setExpiresHeader('P10D'); OC_Response::setExpiresHeader('P10D');
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
require_once('lib_share.php'); require_once('lib_share.php');
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('files_sharing'); OCP\App::checkAppEnabled('files_sharing');
OCP\App::setActiveNavigationEntry("files_sharing_list"); OCP\App::setActiveNavigationEntry("files_sharing_list");
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('gallery'); OCP\App::checkAppEnabled('gallery');
OCP\App::setActiveNavigationEntry( 'gallery_index' ); OCP\App::setActiveNavigationEntry( 'gallery_index' );
if (!file_exists(OCP\Config::getSystemValue("datadirectory").'/'. OCP\USER::getUser() .'/gallery')) { if (!file_exists(OCP\Config::getSystemValue("datadirectory").'/'. OCP\USER::getUser() .'/gallery')) {
......
...@@ -27,7 +27,7 @@ if (!isset($_GET['token']) || empty($_GET['token'])) { ...@@ -27,7 +27,7 @@ if (!isset($_GET['token']) || empty($_GET['token'])) {
OC_Util::checkAppEnabled('gallery'); OCP\App::checkAppEnabled('gallery');
?> ?>
<!doctype html> <!doctype html>
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
// Check if we are a user // Check if we are a user
OCP\User::checkLoggedIn(); OCP\User::checkLoggedIn();
OC_Util::checkAppEnabled('media'); OCP\App::checkAppEnabled('media');
require_once(OC::$APPSROOT . '/apps/media/lib_collection.php'); require_once(OC::$APPSROOT . '/apps/media/lib_collection.php');
require_once(OC::$APPSROOT . '/apps/media/lib_scanner.php'); require_once(OC::$APPSROOT . '/apps/media/lib_scanner.php');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment