diff --git a/.styleci.yml b/.styleci.yml new file mode 100644 index 0000000..fe42f6d --- /dev/null +++ b/.styleci.yml @@ -0,0 +1,2 @@ +preset: laravel + diff --git a/README.md b/README.md index a6b9b7e..7399d17 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,7 @@ [![Latest Version on Packagist][ico-version]][link-packagist] [![Software License][ico-license]](LICENSE.md) [![Build Status][ico-travis]][link-travis] +[![StyleCI][ico-styleci]][link-styleci] [![Total Downloads][ico-downloads]][link-packagist] ## What this is @@ -121,8 +122,10 @@ The MIT License (MIT). Please see [License File](LICENSE.md) for more informatio [ico-version]: https://img.shields.io/packagist/v/kidfund/thin-transit-client.svg?style=flat-square [ico-license]: https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square [ico-travis]: https://img.shields.io/travis/kidfund/thin-transit-client/master.svg?style=flat-square +[ico-styleci]: https://github.styleci.io/repos/157907842/shield?branch=master [ico-downloads]: https://img.shields.io/packagist/dt/kidfund/thin-transit-client.svg?style=flat-square [link-packagist]: https://packagist.org/packages/kidfund/thin-transit-client [link-travis]: https://travis-ci.org/kidfund/thin-transit-client [link-author]: https://github.com/timbroder +[link-styleci]: https://github.styleci.io/repos/157907842 diff --git a/src/TransitClient.php b/src/TransitClient.php index 943ef15..90a33ce 100644 --- a/src/TransitClient.php +++ b/src/TransitClient.php @@ -4,9 +4,9 @@ use GuzzleHttp\Client; use GuzzleHttp\ClientInterface; +use Illuminate\Support\Facades\Log; use GuzzleHttp\Exception\ClientException; use GuzzleHttp\Exception\ServerException; -use Illuminate\Support\Facades\Log; /** * Class TransitClient. @@ -77,11 +77,11 @@ public function encrypt(string $key, string $plaintext, string $context = null) throw new VaultException('Empty response from Vault server'); } - if (!array_key_exists('data', $response)) { + if (! array_key_exists('data', $response)) { throw new VaultException('Vault Encrypt: data not returned'); } - if (!array_key_exists('ciphertext', $response['data'])) { + if (! array_key_exists('ciphertext', $response['data'])) { throw new VaultException('Vault Encrypt: ciphertext not returned'); } diff --git a/tests/ThinTransportClientIntegrationTest.php b/tests/ThinTransportClientIntegrationTest.php index 4c99c8d..cee13d9 100644 --- a/tests/ThinTransportClientIntegrationTest.php +++ b/tests/ThinTransportClientIntegrationTest.php @@ -1,10 +1,10 @@ getGuzzleClient(); }