-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #109 from netgen/upgrade-cloudinary-php-api
Upgrade Cloudinary PHP API from v1 to v2
- Loading branch information
Showing
23 changed files
with
331 additions
and
343 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
lib/Core/Provider/Cloudinary/Factory/CloudinaryConfiguration.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Netgen\RemoteMedia\Core\Provider\Cloudinary\Factory; | ||
|
||
use Cloudinary\Configuration\Configuration; | ||
|
||
final class CloudinaryConfiguration | ||
{ | ||
public function __construct( | ||
private string $cloudName, | ||
private string $apiKey, | ||
private string $apiSecret, | ||
private string $uploadPrefix, | ||
private bool $useSubdomains = false, | ||
) {} | ||
|
||
public function create(): Configuration | ||
{ | ||
return Configuration::instance([ | ||
'cloud_name' => $this->cloudName, | ||
'api_key' => $this->apiKey, | ||
'api_secret' => $this->apiSecret, | ||
'upload_prefix' => $this->uploadPrefix, | ||
'cdn_subdomain' => $this->useSubdomains, | ||
'force_version' => false, | ||
]); | ||
} | ||
} |
39 changes: 0 additions & 39 deletions
39
lib/Core/Provider/Cloudinary/Factory/CloudinaryInstance.php
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.