1
0
Fork 0
mirror of https://github.com/Yetangitu/ampache synced 2025-10-04 18:29:40 +02:00

Use Requests for EchoNest API

This commit is contained in:
Afterster 2013-12-28 17:08:03 +01:00
parent 26b0320c4a
commit 49399b8aea
2 changed files with 2 additions and 1 deletions

View file

@ -190,6 +190,7 @@ switch ($_REQUEST['action']) {
} }
break; break;
case 'show_missing': case 'show_missing':
set_time_limit(600);
$mbid = $_REQUEST['mbid']; $mbid = $_REQUEST['mbid'];
$artistid = $_REQUEST['artist']; $artistid = $_REQUEST['artist'];
$artist = new Artist($artistid); $artist = new Artist($artistid);

View file

@ -218,7 +218,7 @@ class Wanted extends database_object
$song['session'] = session_id(); $song['session'] = session_id();
$song['album_mbid'] = $this->mbid; $song['album_mbid'] = $this->mbid;
if (AmpConfig::get('echonest_api_key')) { if (AmpConfig::get('echonest_api_key')) {
$echonest = new EchoNest_Client(); $echonest = new EchoNest_Client(new EchoNest_HttpClient_Requests());
$echonest->authenticate(AmpConfig::get('echonest_api_key')); $echonest->authenticate(AmpConfig::get('echonest_api_key'));
$enSong = null; $enSong = null;
try { try {