Skip to content

Commit 5adf160

Browse files
author
Jon Baker
committed
Updating for Laravel 6.0
1 parent 4554feb commit 5adf160

File tree

2 files changed

+15
-16
lines changed

2 files changed

+15
-16
lines changed

composer.json

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,19 @@
33
"description": "A boilerplate for contributions.",
44
"homepage": "https://github.com/laravel-notification-channels/twilio",
55
"license": "MIT",
6-
"authors": [
7-
{
8-
"name": "Gregorio Hernández Caso",
9-
"email": "[email protected]",
10-
"homepage": "https://github.com/gregoriohc",
11-
"role": "Developer"
12-
}
13-
],
6+
"authors": [{
7+
"name": "Gregorio Hernández Caso",
8+
"email": "[email protected]",
9+
"homepage": "https://github.com/gregoriohc",
10+
"role": "Developer"
11+
}],
1412
"require": {
1513
"php": ">=5.5.9",
1614
"twilio/sdk": "~5.16",
17-
"illuminate/notifications": "^5.1",
18-
"illuminate/support": "^5.1",
19-
"illuminate/events": "^5.1",
20-
"illuminate/queue": "^5.1"
15+
"illuminate/notifications": "^5.1|^6.0",
16+
"illuminate/support": "^5.1|^6.0",
17+
"illuminate/events": "^5.1|^6.0",
18+
"illuminate/queue": "^5.1|^6.0"
2119
},
2220
"require-dev": {
2321
"mockery/mockery": "^0.9.5",

src/TwilioProvider.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
namespace NotificationChannels\Twilio;
44

5+
use Illuminate\Support\Arr;
56
use Illuminate\Support\ServiceProvider;
67
use Twilio\Rest\Client as TwilioService;
78

@@ -23,14 +24,14 @@ public function boot()
2324

2425
$this->app->bind(TwilioService::class, function () {
2526
$config = $this->app['config']['services.twilio'];
26-
$account_sid = array_get($config, 'account_sid');
27-
$username = array_get($config, 'username');
27+
$account_sid = Arr::get($config, 'account_sid');
28+
$username = Arr::get($config, 'username');
2829
if (! empty($username)) {
29-
$password = array_get($config, 'password');
30+
$password = Arr::get($config, 'password');
3031

3132
return new TwilioService($username, $password, $account_sid);
3233
} else {
33-
$auth_token = array_get($config, 'auth_token');
34+
$auth_token = Arr::get($config, 'auth_token');
3435

3536
return new TwilioService($account_sid, $auth_token);
3637
}

0 commit comments

Comments
 (0)