Introduced common exception superclass
This commit is contained in:
1 parent
f749d4a05e
commit
afafb1ac3d
12 files changed
+48
-28
No files matched your search
@@ -6,7 +6,7 @@
|
||||
|
||||
namespace CloudObjects\SDK\Common;
|
||||
|
||||
use Exception;
|
||||
use CloudObjects\SDK\Exceptions\SDKException;
|
||||
use ML\IRI\IRI;
|
||||
use CloudObjects\SDK\NodeReader;
|
||||
use Defuse\Crypto\Key, Defuse\Crypto\Crypto;
|
||||
@@ -55,7 +55,7 @@ class CryptoHelper {
|
||||
*/
|
||||
public function __construct(ObjectRetriever $objectRetriever, ?IRI $namespaceCoid = null) {
|
||||
if (!class_exists('Defuse\Crypto\Crypto'))
|
||||
throw new Exception("Run composer require defuse/php-encryption before using CryptoHelper.");
|
||||
throw new SDKException("Run composer require defuse/php-encryption before using CryptoHelper.");
|
||||
|
||||
$this->objectRetriever = $objectRetriever;
|
||||
$this->namespace = isset($namespaceCoid)
|
||||
|
||||
Reference in new issue
Block a user