Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitryvasilevskiy committed Sep 8, 2020
1 parent 409681c commit 343c1cf
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/Telegram.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<?php

namespace mttzzz\LaravelTelegramLog;
namespace mttzzz\laravelTelegramLog;

use Exception;
use Illuminate\Http\Client\RequestException;
use Illuminate\Support\Facades\Http;
use Illuminate\Support\Str;
Expand All @@ -11,7 +12,7 @@ class Telegram
public static function log($message)
{
switch ($message) {
case $message instanceof \Exception :
case $message instanceof Exception :
$message = ['message' => $message->getMessage()];
break;
case $message instanceof RequestException :
Expand All @@ -33,7 +34,7 @@ public static function log($message)
}
try {
self::send($message);
} catch (\Exception $e) {
} catch (Exception $e) {
sleep(1);
Telegram::log('упал');
}
Expand Down

0 comments on commit 343c1cf

Please sign in to comment.