mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-10 03:23:19 +00:00
Merge branch '3.8'
Conflicts: lib/classes/Bridge/Api/Dailymotion.php lib/classes/Bridge/Api/Flickr.php lib/classes/Bridge/Api/Interface.php lib/classes/DailymotionWithoutOauth2.php
This commit is contained in:
@@ -425,7 +425,7 @@ class Bridge_Api_Dailymotion extends Bridge_Api_Abstract implements Bridge_Api_I
|
||||
return $this->get_container_from_id(self::CONTAINER_TYPE_PLAYLIST, $container_id);
|
||||
break;
|
||||
default:
|
||||
throw new Bridge_Exception_ContainerUnknown('Unknown element ' . $destination);
|
||||
throw new Bridge_Exception_ContainerUnknown('Unknown element ' . $container);
|
||||
break;
|
||||
}
|
||||
break;
|
||||
@@ -570,8 +570,8 @@ class Bridge_Api_Dailymotion extends Bridge_Api_Abstract implements Bridge_Api_I
|
||||
{
|
||||
switch ($record->get_type()) {
|
||||
case self::ELEMENT_TYPE_VIDEO :
|
||||
$url_file = $this->_api->uploadFileWithToken($record->get_hd_file()->getRealPath(), $this->oauth_token);
|
||||
$options = array_merge(['url' => $url_file], $options);
|
||||
$url_file = $this->_api->sendFile($record->get_hd_file()->getRealPath(), $this->oauth_token);
|
||||
$options = array_merge(array('url' => $url_file), $options);
|
||||
$video = $this->_api->call('POST /me/videos', $options, $this->oauth_token);
|
||||
|
||||
return $video["id"];
|
||||
|
@@ -193,7 +193,7 @@ class Bridge_Api_Flickr extends Bridge_Api_Abstract implements Bridge_Api_Interf
|
||||
throw new Bridge_Exception_ApiConnectorRequestFailed('Unable to retrieve photoset infos for ' . $object);
|
||||
|
||||
$xml = $response->getXml();
|
||||
$primary_photo = $this->get_element_from_id((string) $xml['primary'], self::ELEMENT_TYPE_PHOTO);
|
||||
$primary_photo = $this->get_element_from_id((string) $xml->photo['id'], self::ELEMENT_TYPE_PHOTO);
|
||||
|
||||
return new Bridge_Api_Flickr_Container($xml, $this->get_user_id(), $object, $primary_photo->get_thumbnail());
|
||||
break;
|
||||
|
@@ -9,6 +9,7 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
use Symfony\Component\Routing\Generator\UrlGenerator;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
|
||||
interface Bridge_Api_Interface
|
||||
|
Reference in New Issue
Block a user