Aligned
This commit is contained in:
parent
90d3494576
commit
b069b1254e
|
@ -1182,11 +1182,11 @@ SQL;
|
||||||
if (Application_Model_Preference::GetUploadToSoundcloudOption()) {
|
if (Application_Model_Preference::GetUploadToSoundcloudOption()) {
|
||||||
for ($i=0; $i<$CC_CONFIG['soundcloud-connection-retries']; $i++) {
|
for ($i=0; $i<$CC_CONFIG['soundcloud-connection-retries']; $i++) {
|
||||||
$description = $file->getDbTrackTitle();
|
$description = $file->getDbTrackTitle();
|
||||||
$tag = array();
|
$tag = array();
|
||||||
$genre = $file->getDbGenre();
|
$genre = $file->getDbGenre();
|
||||||
$release = $file->getDbYear();
|
$release = $file->getDbYear();
|
||||||
try {
|
try {
|
||||||
$soundcloud = new Application_Model_Soundcloud();
|
$soundcloud = new Application_Model_Soundcloud();
|
||||||
$soundcloud_res = $soundcloud->uploadTrack(
|
$soundcloud_res = $soundcloud->uploadTrack(
|
||||||
$this->getFilePath(), $this->getName(), $description,
|
$this->getFilePath(), $this->getName(), $description,
|
||||||
$tag, $release, $genre);
|
$tag, $release, $genre);
|
||||||
|
@ -1196,9 +1196,9 @@ SQL;
|
||||||
break;
|
break;
|
||||||
} catch (Services_Soundcloud_Invalid_Http_Response_Code_Exception $e) {
|
} catch (Services_Soundcloud_Invalid_Http_Response_Code_Exception $e) {
|
||||||
$code = $e->getHttpCode();
|
$code = $e->getHttpCode();
|
||||||
$msg = $e->getHttpBody();
|
$msg = $e->getHttpBody();
|
||||||
$temp = explode('"error":',$msg);
|
$temp = explode('"error":',$msg);
|
||||||
$msg = trim($temp[1], '"}');
|
$msg = trim($temp[1], '"}');
|
||||||
$this->setSoundCloudErrorCode($code);
|
$this->setSoundCloudErrorCode($code);
|
||||||
$this->setSoundCloudErrorMsg($msg);
|
$this->setSoundCloudErrorMsg($msg);
|
||||||
// setting sc id to -3 which indicates error
|
// setting sc id to -3 which indicates error
|
||||||
|
|
Loading…
Reference in New Issue