Skip to content

Commit 376272b

Browse files
authored
Update TelegramMessage.php
1 parent 7263feb commit 376272b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/TelegramMessage.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,11 +135,11 @@ public function send(): ResponseInterface|array|null
135135

136136
return $this->telegram->sendMessage($params);
137137
} catch(Exception $exception) {
138-
if(! $this->exceptionHandler) {
139-
throw $exception;
138+
if($this->exceptionHandler) {
139+
$this->exceptionHandler($exception);
140140
}
141141

142-
$this->exceptionHandler($exception);
142+
throw $exception;
143143
}
144144
}
145145

0 commit comments

Comments
 (0)