OCP\App::checkAppEnabled('media'); require_once OC::$APPSROOT . '/apps/media/lib_collection.php'; require_once OC::$APPSROOT . '/apps/media/lib_ampache.php'; $arguments = $_POST; if (!isset($_POST['action']) and isset($_GET['action'])) { $arguments = $_GET; } foreach ($arguments as &$argument) { $argument = stripslashes($argument); } @ob_clean(); if (isset($arguments['action'])) { OCP\Util::writeLog('media', 'ampache ' . $arguments['action'] . ' request', OCP\Util::DEBUG); switch ($arguments['action']) { case 'songs': OC_MEDIA_AMPACHE::songs($arguments); break; case 'url_to_song': OC_MEDIA_AMPACHE::url_to_song($arguments); break; case 'play': OC_MEDIA_AMPACHE::play($arguments); break; case 'handshake': OC_MEDIA_AMPACHE::handshake($arguments); break; case 'ping': OC_MEDIA_AMPACHE::ping($arguments); break; case 'artists': OC_MEDIA_AMPACHE::artists($arguments);