diff options
author | beardyman <nornholdj@gmail.com> | 2015-10-02 17:20:54 -0400 |
---|---|---|
committer | beardyman <nornholdj@gmail.com> | 2015-10-02 17:20:54 -0400 |
commit | 1c386dcd13af959f8bb98115751b75f214c4e409 (patch) | |
tree | cdf54bbcf41f87ee1edc0aad272a5101de06f0af | |
parent | 6818faa620c5b2e4f384d34e3156606938a2dbc1 (diff) | |
download | php-sparkpost-1c386dcd13af959f8bb98115751b75f214c4e409.zip php-sparkpost-1c386dcd13af959f8bb98115751b75f214c4e409.tar.gz php-sparkpost-1c386dcd13af959f8bb98115751b75f214c4e409.tar.bz2 |
Removed all tabs and replaced them with two spaces
-rw-r--r-- | README.md | 8 | ||||
-rw-r--r-- | composer.json | 2 | ||||
-rw-r--r-- | examples/bootstrap.php | 2 | ||||
-rw-r--r-- | examples/transmission/get_all_transmissions.php | 2 | ||||
-rw-r--r-- | examples/transmission/get_transmission.php | 2 | ||||
-rw-r--r-- | examples/transmission/rfc822.php | 2 | ||||
-rw-r--r-- | examples/transmission/send_transmission_all_fields.php | 2 | ||||
-rw-r--r-- | examples/transmission/simple_send.php | 2 | ||||
-rw-r--r-- | examples/transmission/stored_recipients_inline_content.php | 2 | ||||
-rw-r--r-- | examples/transmission/stored_template_send.php | 2 | ||||
-rw-r--r-- | examples/unwrapped/create_template.php | 2 | ||||
-rw-r--r-- | lib/SendGridCompatibility/Email.php | 2 | ||||
-rw-r--r-- | lib/SendGridCompatibility/SendGrid.php | 2 | ||||
-rw-r--r-- | lib/SparkPost/APIResource.php | 2 | ||||
-rw-r--r-- | lib/SparkPost/SparkPost.php | 2 | ||||
-rw-r--r-- | lib/SparkPost/Transmission.php | 2 | ||||
-rw-r--r-- | test/unit/APIResourceTest.php | 2 | ||||
-rw-r--r-- | test/unit/SendGridCompatibiility/EmailTest.php | 2 | ||||
-rw-r--r-- | test/unit/SparkPostTest.php | 9 | ||||
-rw-r--r-- | test/unit/bootstrap.php | 2 |
20 files changed, 26 insertions, 27 deletions
@@ -19,7 +19,7 @@ Next, run the Composer command to install the SparkPost PHP SDK: composer require sparkpost/php-sparkpost ``` After installing, you need to require Composer's autoloader: -``` +```php require 'vendor/autoload.php'; use SparkPost\SparkPost; ``` @@ -33,7 +33,7 @@ need to require one and create an adapter from it and pass it along. The exampl GuzzleHttp Client Library. An Adapter can be setup like so: -``` +```php use SparkPost\SparkPost; use GuzzleHttp\Client; use Ivory\HttpAdapter\Guzzle6HttpAdapter; @@ -43,7 +43,7 @@ $sparky = new SparkPost($httpAdapter, ['key'=>'YOUR API KEY']); ``` ## Getting Started: Your First Mailing -``` +```php require 'vendor/autoload.php'; use SparkPost\SparkPost; @@ -55,7 +55,7 @@ $sparky = new SparkPost($httpAdapter, ['key'=>'YOUR API KEY']); try { // Build your email and send it! - $results = $sparky->transmission->send([ + $results = $sparky->transmission->send([ 'from'=>'From Envelope <from@sparkpostbox.com>', 'html'=>'<html><body><h1>Congratulations, {{name}}!</h1><p>You just sent your very first mailing!</p></body></html>', 'text'=>'Congratulations, {{name}}!! You just sent your very first mailing!', diff --git a/composer.json b/composer.json index a100cde..7bb7a6e 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,7 @@ "test": "phpunit ./test/unit/" }, "require": { - "php": ">=5.5.0", + "php": ">=5.5.0", "egeloen/http-adapter": "*" }, "require-dev": { diff --git a/examples/bootstrap.php b/examples/bootstrap.php index 8a5f839..774b159 100644 --- a/examples/bootstrap.php +++ b/examples/bootstrap.php @@ -1,3 +1,3 @@ <?php - require_once dirname(__FILE__).'/../vendor/autoload.php'; + require_once dirname(__FILE__).'/../vendor/autoload.php'; ?>
\ No newline at end of file diff --git a/examples/transmission/get_all_transmissions.php b/examples/transmission/get_all_transmissions.php index 7baf4f1..73eed92 100644 --- a/examples/transmission/get_all_transmissions.php +++ b/examples/transmission/get_all_transmissions.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - $results = $sparky->transmission->all(); + $results = $sparky->transmission->all(); echo 'Congrats you can use your SDK!'; } catch (\Exception $exception) { echo $exception->getMessage(); diff --git a/examples/transmission/get_transmission.php b/examples/transmission/get_transmission.php index 1e749b9..f6af649 100644 --- a/examples/transmission/get_transmission.php +++ b/examples/transmission/get_transmission.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - $results = $sparky->transmission->find('Your Transmission ID'); + $results = $sparky->transmission->find('Your Transmission ID'); echo 'Congrats you can use your SDK!'; } catch (\Exception $exception) { echo $exception->getMessage(); diff --git a/examples/transmission/rfc822.php b/examples/transmission/rfc822.php index b11b34f..8221097 100644 --- a/examples/transmission/rfc822.php +++ b/examples/transmission/rfc822.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - $results = $sparky->transmission->send([ + $results = $sparky->transmission->send([ 'recipients'=>[ [ 'address'=>[ diff --git a/examples/transmission/send_transmission_all_fields.php b/examples/transmission/send_transmission_all_fields.php index 044dcc2..c9766ce 100644 --- a/examples/transmission/send_transmission_all_fields.php +++ b/examples/transmission/send_transmission_all_fields.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try{ - $results = $sparky->transmission->send([ + $results = $sparky->transmission->send([ "campaign"=>"my-campaign", "metadata"=>[ "sample_campaign"=>true, diff --git a/examples/transmission/simple_send.php b/examples/transmission/simple_send.php index 6dc3719..30b5c4e 100644 --- a/examples/transmission/simple_send.php +++ b/examples/transmission/simple_send.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - $results = $sparky->transmission->send([ + $results = $sparky->transmission->send([ "from"=>"From Envelope <from@sparkpostbox.com>", "html"=>"<p>Hello World!</p>", "text"=>"Hello World!", diff --git a/examples/transmission/stored_recipients_inline_content.php b/examples/transmission/stored_recipients_inline_content.php index 3e53507..8a30d7e 100644 --- a/examples/transmission/stored_recipients_inline_content.php +++ b/examples/transmission/stored_recipients_inline_content.php @@ -15,7 +15,7 @@ $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - $results = $sparky->transmission->send([ + $results = $sparky->transmission->send([ "campaign"=>"my-campaign", "from"=>"From Envelope <from@sparkpostbox.com>", "html"=>"<p>Hello World! Your name is: {{name}}</p>", diff --git a/examples/transmission/stored_template_send.php b/examples/transmission/stored_template_send.php index 936d292..5cf1cf3 100644 --- a/examples/transmission/stored_template_send.php +++ b/examples/transmission/stored_template_send.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - $results = $sparky->transmission->send([ + $results = $sparky->transmission->send([ "from"=>"From Envelope <from@sparkpostbox.com>", "recipients"=>[ [ diff --git a/examples/unwrapped/create_template.php b/examples/unwrapped/create_template.php index e28f158..d92b294 100644 --- a/examples/unwrapped/create_template.php +++ b/examples/unwrapped/create_template.php @@ -14,7 +14,7 @@ $httpAdapter = new Guzzle6HttpAdapter(new Client()); $sparky = new SparkPost($httpAdapter, ['key'=>$config['api-key']]); try { - // define the endpoint + // define the endpoint $sparky->setupUnwrapped('templates'); $templateConfig = [ diff --git a/lib/SendGridCompatibility/Email.php b/lib/SendGridCompatibility/Email.php index 5351324..5576176 100644 --- a/lib/SendGridCompatibility/Email.php +++ b/lib/SendGridCompatibility/Email.php @@ -2,7 +2,7 @@ namespace SparkPost\SendGridCompatibility; class Email { - public $model; + public $model; /** diff --git a/lib/SendGridCompatibility/SendGrid.php b/lib/SendGridCompatibility/SendGrid.php index b92457b..25e5d54 100644 --- a/lib/SendGridCompatibility/SendGrid.php +++ b/lib/SendGridCompatibility/SendGrid.php @@ -7,7 +7,7 @@ use SparkPost\SendGridCompatibility\Email; class SendGrid{ private $sparky; - public function __construct($username, $password, $options = null, $httpAdapter) { + public function __construct($username, $password, $options = null, $httpAdapter) { //username isn't used in our system $opts = array('key'=>$password); if (!is_null($options)) { diff --git a/lib/SparkPost/APIResource.php b/lib/SparkPost/APIResource.php index 4c4cf08..d500963 100644 --- a/lib/SparkPost/APIResource.php +++ b/lib/SparkPost/APIResource.php @@ -8,7 +8,7 @@ use SparkPost\SparkPost; */ class APIResource { - /** + /** * @desc name of the API endpoint, mainly used for URL construction. * This is public to provide an interface * diff --git a/lib/SparkPost/SparkPost.php b/lib/SparkPost/SparkPost.php index 83200c0..d9dc3c8 100644 --- a/lib/SparkPost/SparkPost.php +++ b/lib/SparkPost/SparkPost.php @@ -21,7 +21,7 @@ class SparkPost { * @desc Default config values. Passed in values will override these. */ private static $apiDefaults = [ - 'host'=>'api.sparkpost.com', + 'host'=>'api.sparkpost.com', 'protocol'=>'https', 'port'=>443, 'strictSSL'=>true, diff --git a/lib/SparkPost/Transmission.php b/lib/SparkPost/Transmission.php index 3b3c056..f811cdf 100644 --- a/lib/SparkPost/Transmission.php +++ b/lib/SparkPost/Transmission.php @@ -8,7 +8,7 @@ use Guzzle\Http\Exception\ClientErrorResponseException; */ class Transmission extends APIResource { - public $endpoint = 'transmissions'; + public $endpoint = 'transmissions'; /** * @desc Mapping for values passed into the send method to the values needed for the Transmission API diff --git a/test/unit/APIResourceTest.php b/test/unit/APIResourceTest.php index 132d6e2..b64093d 100644 --- a/test/unit/APIResourceTest.php +++ b/test/unit/APIResourceTest.php @@ -18,7 +18,7 @@ class APIResourceTest extends \PHPUnit_Framework_TestCase { return $exception; } - /** + /** * (non-PHPdoc) * @before * @see PHPUnit_Framework_TestCase::setUp() diff --git a/test/unit/SendGridCompatibiility/EmailTest.php b/test/unit/SendGridCompatibiility/EmailTest.php index c60801c..1c7311d 100644 --- a/test/unit/SendGridCompatibiility/EmailTest.php +++ b/test/unit/SendGridCompatibiility/EmailTest.php @@ -2,7 +2,7 @@ use SparkPost\SendGridCompatibility\Email; class SendGridCompatibilityEmailTest extends \PHPUnit_Framework_TestCase { - + private $email; public function setup() { diff --git a/test/unit/SparkPostTest.php b/test/unit/SparkPostTest.php index aeda7d7..cd45c5a 100644 --- a/test/unit/SparkPostTest.php +++ b/test/unit/SparkPostTest.php @@ -29,12 +29,11 @@ class SparkPostTest extends \PHPUnit_Framework_TestCase { self::$utils->setProperty($this->resource, 'httpAdapter', $this->adapterMock); } - public function tearDown() - { - Mockery::close(); - } + public function tearDown(){ + Mockery::close(); + } - /** + /** * @desc Ensures that the configuration class is not instantiable. */ public function testConstructorSetsUpTransmissions() { diff --git a/test/unit/bootstrap.php b/test/unit/bootstrap.php index 835369b..0b851be 100644 --- a/test/unit/bootstrap.php +++ b/test/unit/bootstrap.php @@ -1,3 +1,3 @@ <?php - require_once dirname(__FILE__).'/../../vendor/autoload.php'; + require_once dirname(__FILE__).'/../../vendor/autoload.php'; ?> |