Remove no longer used exception
[MAILPOET-4946]
This commit is contained in:
@ -9,7 +9,6 @@ use MailPoet\Automation\Engine\Exceptions\UnexpectedValueException;
|
||||
use MailPoet\Automation\Engine\Utils\Json;
|
||||
|
||||
class Exceptions {
|
||||
private const MIGRATION_FAILED = 'mailpoet_automation_migration_failed';
|
||||
private const DATABASE_ERROR = 'mailpoet_automation_database_error';
|
||||
private const JSON_NOT_OBJECT = 'mailpoet_automation_json_not_object';
|
||||
private const AUTOMATION_NOT_FOUND = 'mailpoet_automation_not_found';
|
||||
@ -43,13 +42,6 @@ class Exceptions {
|
||||
);
|
||||
}
|
||||
|
||||
public static function migrationFailed(string $error): InvalidStateException {
|
||||
return InvalidStateException::create()
|
||||
->withErrorCode(self::MIGRATION_FAILED)
|
||||
// translators: %s is the error message.
|
||||
->withMessage(sprintf(__('Migration failed: %s', 'mailpoet'), $error));
|
||||
}
|
||||
|
||||
public static function databaseError(string $error): InvalidStateException {
|
||||
return InvalidStateException::create()
|
||||
->withErrorCode(self::DATABASE_ERROR)
|
||||
|
Reference in New Issue
Block a user