BrandNotSetException.php in Bynder 8
File
src/Exception/BrandNotSetException.php
View source
<?php
namespace Drupal\bynder\Exception;
use Drupal\Core\Url;
class BrandNotSetException extends BynderException {
public function __construct($entity_browser_id) {
$log_message = 'Brand to upload to is not set. Check the <a target="_blank" href=":url">configuration of the widget</a>.';
$log_message_args = [
':url' => Url::fromRoute('entity.entity_browser.edit_form', [
'entity_browser' => $entity_browser_id,
'step' => 'widgets',
])
->toString(),
];
$admin_message = $this
->t($log_message, $log_message_args);
$message = $this
->t('Brand to upload to is not set. Please contact the site administrator.');
parent::__construct($message, $admin_message, $log_message, $log_message_args);
}
}