port checkAppEnabled
This commit is contained in:
parent
eec7c3833c
commit
4fe90f62f4
|
@ -23,7 +23,7 @@
|
|||
*
|
||||
*/
|
||||
OCP\User::checkAdminUser();
|
||||
OC_Util::checkAppEnabled('admin_migrate');
|
||||
OCP\App::checkAppEnabled('admin_migrate');
|
||||
|
||||
// Export?
|
||||
if (isset($_POST['admin_export'])) {
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
// Check if we are a user
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('bookmarks');
|
||||
OCP\App::checkAppEnabled('bookmarks');
|
||||
|
||||
require_once('bookmarksHelper.php');
|
||||
addBookmark($_GET['url'], '', 'Read-Later');
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
// Check if we are a user
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('bookmarks');
|
||||
OCP\App::checkAppEnabled('bookmarks');
|
||||
|
||||
OCP\App::setActiveNavigationEntry( 'bookmarks_index' );
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
|
||||
OC_JSON::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('calendar');
|
||||
OCP\App::checkAppEnabled('calendar');
|
||||
$tmpl = new OC_Template('calendar', 'part.import');
|
||||
$tmpl->assign('path', $_POST['path']);
|
||||
$tmpl->assign('filename', $_POST['filename']);
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
//check for calendar rights or create new one
|
||||
ob_start();
|
||||
OC_JSON::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('calendar');
|
||||
OCP\App::checkAppEnabled('calendar');
|
||||
$nl="\r\n";
|
||||
$comps = array('VEVENT'=>true, 'VTODO'=>true, 'VJOURNAL'=>true);
|
||||
$progressfile = 'import_tmp/' . md5(session_id()) . '.txt';
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
$RUNTIME_NOSETUPFS = true;
|
||||
require_once('../lib/base.php');
|
||||
|
||||
OC_Util::checkAppEnabled('calendar');
|
||||
OCP\App::checkAppEnabled('calendar');
|
||||
|
||||
// Backends
|
||||
$authBackend = new OC_Connector_Sabre_Auth();
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('calendar');
|
||||
OCP\App::checkAppEnabled('calendar');
|
||||
$cal = isset($_GET['calid']) ? $_GET['calid'] : NULL;
|
||||
$event = isset($_GET['eventid']) ? $_GET['eventid'] : NULL;
|
||||
$nl = "\r\n";
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('calendar');
|
||||
OCP\App::checkAppEnabled('calendar');
|
||||
|
||||
// Create default calendar ...
|
||||
$calendars = OC_Calendar_Calendar::allCalendars(OCP\USER::getUser(), 1);
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
require_once('../../../lib/base.php');
|
||||
OC_JSON::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
$upload_max_filesize = OCP\Util::computerFileSize(ini_get('upload_max_filesize'));
|
||||
$post_max_size = OCP\Util::computerFileSize(ini_get('post_max_size'));
|
||||
$maxUploadFilesize = min($upload_max_filesize, $post_max_size);
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
|
||||
OC_JSON::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
$tmpl = new OC_Template('contacts', 'part.import');
|
||||
$tmpl->assign('path', $_POST['path']);
|
||||
$tmpl->assign('filename', $_POST['filename']);
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
$RUNTIME_NOSETUPFS = true;
|
||||
require_once('../lib/base.php');
|
||||
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
|
||||
// Backends
|
||||
$authBackend = new OC_Connector_Sabre_Auth();
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
$bookid = isset($_GET['bookid']) ? $_GET['bookid'] : NULL;
|
||||
$contactid = isset($_GET['contactid']) ? $_GET['contactid'] : NULL;
|
||||
$nl = "\n";
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
ob_start();
|
||||
|
||||
OC_JSON::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
$nl = "\n";
|
||||
$progressfile = 'import_tmp/' . md5(session_id()) . '.txt';
|
||||
if(is_writable('import_tmp/')){
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
// Check if we are a user
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
|
||||
// Get active address books. This creates a default one if none exists.
|
||||
$ids = OC_Contacts_Addressbook::activeIds(OCP\USER::getUser());
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
// Init owncloud
|
||||
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
|
||||
function getStandardImage(){
|
||||
OC_Response::setExpiresHeader('P10D');
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
OC_JSON::checkLoggedIn();
|
||||
//OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('contacts');
|
||||
OCP\App::checkAppEnabled('contacts');
|
||||
|
||||
function getStandardImage(){
|
||||
OC_Response::setExpiresHeader('P10D');
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
require_once('lib_share.php');
|
||||
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('files_sharing');
|
||||
OCP\App::checkAppEnabled('files_sharing');
|
||||
|
||||
OCP\App::setActiveNavigationEntry("files_sharing_list");
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
|
||||
OCP\User::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('gallery');
|
||||
OCP\App::checkAppEnabled('gallery');
|
||||
OCP\App::setActiveNavigationEntry( 'gallery_index' );
|
||||
|
||||
if (!file_exists(OCP\Config::getSystemValue("datadirectory").'/'. OCP\USER::getUser() .'/gallery')) {
|
||||
|
|
|
@ -27,7 +27,7 @@ if (!isset($_GET['token']) || empty($_GET['token'])) {
|
|||
|
||||
|
||||
|
||||
OC_Util::checkAppEnabled('gallery');
|
||||
OCP\App::checkAppEnabled('gallery');
|
||||
|
||||
?>
|
||||
<!doctype html>
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
|
||||
// Check if we are a user
|
||||
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_scanner.php');
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
|
||||
require_once('../../inc.php');
|
||||
|
||||
OC_Util::checkAppEnabled('media');
|
||||
OCP\App::checkAppEnabled('media');
|
||||
require_once(OC::$APPSROOT . '/apps/media/lib_collection.php');
|
||||
require_once(OC::$APPSROOT . '/apps/media/lib_ampache.php');
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
$RUNTIME_NOSETUPFS = true;
|
||||
|
||||
|
||||
OC_Util::checkAppEnabled('remoteStorage');
|
||||
OCP\App::checkAppEnabled('remoteStorage');
|
||||
require_once('Sabre/autoload.php');
|
||||
require_once('lib_remoteStorage.php');
|
||||
require_once('BearerAuth.php');
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
$RUNTIME_NOSETUPFS = true;
|
||||
|
||||
|
||||
OC_Util::checkAppEnabled('remoteStorage');
|
||||
OCP\App::checkAppEnabled('remoteStorage');
|
||||
require_once('Sabre/autoload.php');
|
||||
require_once('../lib_remoteStorage.php');
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
$RUNTIME_NOSETUPFS = true;
|
||||
|
||||
|
||||
OC_Util::checkAppEnabled('remoteStorage');
|
||||
OCP\App::checkAppEnabled('remoteStorage');
|
||||
require_once('Sabre/autoload.php');
|
||||
require_once('lib_remoteStorage.php');
|
||||
require_once('oauth_ro_auth.php');
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
*
|
||||
*/
|
||||
OCP\User::checkAdminUser();
|
||||
OC_Util::checkAppEnabled('user_migrate');
|
||||
OCP\App::checkAppEnabled('user_migrate');
|
||||
|
||||
// Import?
|
||||
if (isset($_POST['user_import'])) {
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
// Check if we are a user
|
||||
OC_JSON::checkLoggedIn();
|
||||
OC_Util::checkAppEnabled('user_migrate');
|
||||
OCP\App::checkAppEnabled('user_migrate');
|
||||
// Which operation
|
||||
if( $_GET['operation']=='create' ){
|
||||
$uid = !empty( $_POST['uid'] ) ? $_POST['uid'] : OCP\USER::getUser();
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
* License along with this library. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
OC_Util::checkAppEnabled('user_migrate');
|
||||
OCP\App::checkAppEnabled('user_migrate');
|
||||
|
||||
// fill template
|
||||
$tmpl = new OC_Template('user_migrate', 'settings');
|
||||
|
|
|
@ -37,7 +37,7 @@ if($USERNAME=='' and isset($_SERVER['PHP_AUTH_USER'])){
|
|||
$RUNTIME_NOAPPS=true;
|
||||
$RUNTIME_NOAPPS=false;
|
||||
require_once '../../lib/base.php';
|
||||
OC_Util::checkAppEnabled('user_openid');
|
||||
OCP\App::checkAppEnabled('user_openid');
|
||||
|
||||
if(!OCP\User::userExists($USERNAME)){
|
||||
OCP\Util::writeLog('user_openid',$USERNAME.' doesn\'t exist',OCP\Util::WARN);
|
||||
|
|
Loading…
Reference in New Issue