summaryrefslogtreecommitdiffstats
path: root/apps/media
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2012-05-08 18:40:27 +0200
committerBart Visscher <bartv@thisnet.nl>2012-05-08 18:40:40 +0200
commit4f88fadbc1c508ef40828eaf5920c97681e1fab6 (patch)
treec638d5b6ffc735bd5f6ff140c3b94f94c50b4c2e /apps/media
parentda1da8197ed583219dc2b6cde4cf1249974b050c (diff)
downloadnextcloud-server-4f88fadbc1c508ef40828eaf5920c97681e1fab6.tar.gz
nextcloud-server-4f88fadbc1c508ef40828eaf5920c97681e1fab6.zip
Add remote for media/tomahawk.php
Diffstat (limited to 'apps/media')
-rwxr-xr-xapps/media/appinfo/app.php3
-rwxr-xr-xapps/media/tomahawk.php4
2 files changed, 3 insertions, 4 deletions
diff --git a/apps/media/appinfo/app.php b/apps/media/appinfo/app.php
index 0ab6543e070..332b73546ec 100755
--- a/apps/media/appinfo/app.php
+++ b/apps/media/appinfo/app.php
@@ -32,4 +32,5 @@ OCP\App::register( array( 'order' => 3, 'id' => 'media', 'name' => 'Media' ));
OCP\App::addNavigationEntry(array('id' => 'media_index', 'order' => 2, 'href' => OCP\Util::linkTo('media', 'index.php'), 'icon' => OCP\Util::imagePath('core', 'places/music.svg'), 'name' => $l->t('Music')));
OC_Search::registerProvider('OC_MediaSearchProvider');
-OCP\CONFIG::setAppValue('core', 'remote_ampache', '/apps/media/remote.php'); \ No newline at end of file
+OCP\CONFIG::setAppValue('core', 'remote_ampache', '/apps/media/remote.php');
+OCP\CONFIG::setAppValue('core', 'remote_tomahawk', '/apps/media/tomahawk.php');
diff --git a/apps/media/tomahawk.php b/apps/media/tomahawk.php
index 700a75bf41e..c74d168c42d 100755
--- a/apps/media/tomahawk.php
+++ b/apps/media/tomahawk.php
@@ -22,7 +22,6 @@
*/
$_POST=$_GET; //debug
-require_once('../inc.php');
OCP\JSON::checkAppEnabled('media');
require_once(OC::$APPSROOT . '/apps/media/lib_collection.php');
@@ -58,7 +57,7 @@ $album=OC_MEDIA_COLLECTION::getAlbumId($album,$artist);
$songs=OC_MEDIA_COLLECTION::getSongs($artist,$album,$song);
-$baseUrl=OC_Util::getServerURL().OCP\Util::linkTo('media','tomahawk.php');
+$baseUrl=$baseuri;
$results=array();
foreach($songs as $song) {
@@ -77,4 +76,3 @@ foreach($songs as $song) {
);
}
OCP\JSON::encodedPrint($results);
-?>