diff --git a/README.md b/README.md index 45d0878..84e165c 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ This library includes support for automatically signing Guzzle requests using an ```php use HttpSignatures\Context; -use HttpSignatures\Guzzle\CreateRequestSubscriber; +use HttpSignatures\Guzzle\RequestSubscriber; $context = new Context(array( 'keys' => array('examplekey' => 'secret-key-here'), @@ -21,7 +21,7 @@ $context = new Context(array( )); $client = new \Guzzle\Http\Client('http://example.org'); -$client->addSubscriber(new CreateRequestSubscriber($context)); +$client->addSubscriber(new RequestSubscriber($context)); // The below will now send a signed request to: http://example.org/path?query=123 $client->get('/path?query=123', array( diff --git a/src/HttpSignatures/Guzzle/CreateRequestSubscriber.php b/src/HttpSignatures/Guzzle/RequestSubscriber.php similarity index 88% rename from src/HttpSignatures/Guzzle/CreateRequestSubscriber.php rename to src/HttpSignatures/Guzzle/RequestSubscriber.php index d3f50fb..bf28ff2 100644 --- a/src/HttpSignatures/Guzzle/CreateRequestSubscriber.php +++ b/src/HttpSignatures/Guzzle/RequestSubscriber.php @@ -5,7 +5,7 @@ namespace HttpSignatures\Guzzle; use Guzzle\Common\Event; use Symfony\Component\EventDispatcher\EventSubscriberInterface; -class CreateRequestSubscriber implements EventSubscriberInterface +class RequestSubscriber implements EventSubscriberInterface { private $context; diff --git a/tests/GuzzleSignerTest.php b/tests/GuzzleSignerTest.php index 3e7e91b..6993148 100644 --- a/tests/GuzzleSignerTest.php +++ b/tests/GuzzleSignerTest.php @@ -2,7 +2,7 @@ namespace HttpSignatures\Test; -use HttpSignatures\Guzzle\CreateRequestSubscriber; +use HttpSignatures\Guzzle\RequestSubscriber; use HttpSignatures\Context; use HttpSignatures\Guzzle\Message; @@ -17,7 +17,7 @@ class GuzzleSignerTest extends \PHPUnit_Framework_TestCase )); $this->client = new \Guzzle\Http\Client(); - $this->client->addSubscriber(new CreateRequestSubscriber($this->context)); + $this->client->addSubscriber(new RequestSubscriber($this->context)); } public function testGuzzleRequestHasExpectedHeaders()