aboutsummaryrefslogtreecommitdiffhomepage
path: root/Digitigrade/Model/Instance.php
diff options
context:
space:
mode:
Diffstat (limited to 'Digitigrade/Model/Instance.php')
-rw-r--r--Digitigrade/Model/Instance.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/Digitigrade/Model/Instance.php b/Digitigrade/Model/Instance.php
index 2b07b9a..c689657 100644
--- a/Digitigrade/Model/Instance.php
+++ b/Digitigrade/Model/Instance.php
@@ -1,6 +1,7 @@
<?php
namespace Digitigrade\Model;
+use Digitigrade\Exception\AuthException;
use Digitigrade\Exception\EndpointMissingException;
use Digitigrade\GlobalConfig;
use Digitigrade\Job\RefreshOutboundAuthToken;
@@ -193,7 +194,7 @@ class Instance extends FetchableModel {
throw new EndpointMissingException($this, 'push');
}
if (!isset($this->auth->outboundToken)) {
- throw new \RuntimeException("can't push to $this->domain because i don't have an outbound token for it");
+ throw new AuthException($this);
}
if (!$this->auth->outboundPushEnabled) {
throw new \RuntimeException("won't push to $this->domain because it hasn't subscribed to us");