Skip to content

Commit

Permalink
Fixed sending notifications when testing environment
Browse files Browse the repository at this point in the history
  • Loading branch information
tabuna committed Mar 27, 2024
1 parent 8a4f3e2 commit 74b8d3d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/Services/TelegramBot.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace App\Services;

use Illuminate\Http\Client\Response;
use Illuminate\Support\Arr;
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\Facades\Http;
use Illuminate\Support\Str;
Expand Down Expand Up @@ -108,7 +109,7 @@ public function isSpam(?string $message, $userId = null): bool
*/
public static function notificationToTelegram($exception): void
{
if (config('app.env') == 'local') {
if (Arr::has(['local', 'testing'], config('app.env'))) {
return;
}

Expand Down

0 comments on commit 74b8d3d

Please sign in to comment.