Created
April 4, 2017 17:44
-
-
Save maxheckel/35b7f234ef409a378349c96ca3226900 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| namespace App\Providers; | |
| use App\Services\UPS; | |
| use UPS\Client; | |
| use Illuminate\Support\ServiceProvider; | |
| class UPSServiceProvider extends ServiceProvider | |
| { | |
| /** | |
| * Bootstrap the application services. | |
| * | |
| * @return void | |
| */ | |
| public function boot() | |
| { | |
| } | |
| /** | |
| * Register the application services. | |
| * | |
| * @return void | |
| */ | |
| public function register() | |
| { | |
| \App::bind('ups', function(){ | |
| $config = [ | |
| 'username'=>env('UPS_USERNAME'), | |
| 'password'=>env('UPS_PASSWORD') | |
| ]; | |
| return new UPS(new Client($config)); | |
| }); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment