Blame view

sources/settings/ajax/disableapp.php 238 Bytes
03e52840d   Kload   Init
1
  <?php
6d9380f96   Cédric Dupont   Update sources OC...
2
  OCP\JSON::checkAdminUser();
03e52840d   Kload   Init
3
  OCP\JSON::callCheck();
6d9380f96   Cédric Dupont   Update sources OC...
4
5
6
7
  if (!array_key_exists('appid', $_POST)) {
  	OC_JSON::error();
  	exit;
  }
03e52840d   Kload   Init
8

6d9380f96   Cédric Dupont   Update sources OC...
9
10
11
12
  $appId = $_POST['appid'];
  $appId = OC_App::cleanAppId($appId);
  
  OC_App::disable($appId);
03e52840d   Kload   Init
13
  OC_JSON::success();