mailjet / laravel-mailjet

Laravel package for Mailjet API V3 and Laravel Mailjet Mail Transport
MIT License
94 stars 93 forks source link

Wrong response object passed to throwError() #3

Closed danieldoinov closed 7 years ago

danieldoinov commented 7 years ago

Hello, If a call to the API returns enything else then success the MailJet throws an error. Which is god but its the wrong error :) . Instead of throwing whats wrong with the service it throws this one :

Argument 2 passed to Mailjet\LaravelMailjet\Services\MailjetService::throwError() must be an instance of Mailjet\LaravelMailjet\Services\Response, instance of Mailjet\Response given, called in D:\xampp\htdocs\Laravel\vendor\mailjet\laravel-mailjet\src\Services\MailjetService.php on line 39 and defined

Nightbr commented 7 years ago

Hey, can you test with the last release (composer update mailjet/laravel-mailjet), we have fixed this!