From e32f4e5a49efa1a9a895aac51262c903bd7cd576 Mon Sep 17 00:00:00 2001 From: Jan Iwanow Date: Sun, 12 Apr 2020 12:13:49 +0700 Subject: [PATCH] support for newer Laravel versions --- composer.json | 5 +---- src/SmppService.php | 3 ++- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/composer.json b/composer.json index 8a6d4c3..f1e6998 100644 --- a/composer.json +++ b/composer.json @@ -10,10 +10,7 @@ ], "require": { "php-smpp/php-smpp": "1.2", - "illuminate/support": "^5.2" - }, - "require-dev": { - "phpunit/phpunit": "~5.0" + "illuminate/support": "^5|^6|^7" }, "autoload": { "psr-4": { diff --git a/src/SmppService.php b/src/SmppService.php index b57dabc..f0a3309 100644 --- a/src/SmppService.php +++ b/src/SmppService.php @@ -4,6 +4,7 @@ use Exception; use Illuminate\Contracts\Config\Repository; +use Illuminate\Support\Arr; use Log; use SMPP; use SmppAddress; @@ -240,6 +241,6 @@ protected function getConfig($option) $key = $this->provider . '.' . $option; $default = $this->config->get(sprintf('laravel-smpp.defaults.%s', $option)); - return array_get($this->providers, $key, $default); + return Arr::get($this->providers, $key, $default); } } \ No newline at end of file