diff --git a/src/Eher/OAuth/OAuthServer.php b/src/Eher/OAuth/OAuthServer.php index 8a8b913..55e7fc2 100644 --- a/src/Eher/OAuth/OAuthServer.php +++ b/src/Eher/OAuth/OAuthServer.php @@ -94,7 +94,7 @@ class OAuthServer { * figure out the signature with some defaults */ private function get_signature_method($request) { - $signature_method = $request instanceof OAuthRequest + $signature_method = $request instanceof Request ? $request->get_parameter("oauth_signature_method") : NULL; @@ -119,7 +119,7 @@ class OAuthServer { * try to find the consumer for the provided request's consumer key */ private function get_consumer($request) { - $consumer_key = $request instanceof OAuthRequest + $consumer_key = $request instanceof Request ? $request->get_parameter("oauth_consumer_key") : NULL; @@ -139,7 +139,7 @@ class OAuthServer { * try to find the token for the provided request's token key */ private function get_token($request, $consumer, $token_type="access") { - $token_field = $request instanceof OAuthRequest + $token_field = $request instanceof Request ? $request->get_parameter('oauth_token') : NULL; @@ -158,10 +158,10 @@ class OAuthServer { */ private function check_signature($request, $consumer, $token) { // this should probably be in a different method - $timestamp = $request instanceof OAuthRequest + $timestamp = $request instanceof Request ? $request->get_parameter('oauth_timestamp') : NULL; - $nonce = $request instanceof OAuthRequest + $nonce = $request instanceof Request ? $request->get_parameter('oauth_nonce') : NULL; diff --git a/src/Eher/OAuth/PlainText.php b/src/Eher/OAuth/PlainText.php index f834807..895aeed 100644 --- a/src/Eher/OAuth/PlainText.php +++ b/src/Eher/OAuth/PlainText.php @@ -19,7 +19,7 @@ class PlainText extends SignatureMethod { * - Chapter 9.4.1 ("Generating Signatures") * * Please note that the second encoding MUST NOT happen in the SignatureMethod, as - * OAuthRequest handles this! + * Request handles this! */ public function build_signature($request, $consumer, $token) { $key_parts = array( diff --git a/src/Eher/OAuth/SignatureMethod.php b/src/Eher/OAuth/SignatureMethod.php index bad2b9f..9629818 100644 --- a/src/Eher/OAuth/SignatureMethod.php +++ b/src/Eher/OAuth/SignatureMethod.php @@ -16,9 +16,9 @@ abstract class SignatureMethod { /** * Build up the signature * NOTE: The output of this function MUST NOT be urlencoded. - * the encoding is handled in OAuthRequest when the final + * the encoding is handled in Request when the final * request is serialized - * @param OAuthRequest $request + * @param Request $request * @param OAuthConsumer $consumer * @param OAuthToken $token * @return string @@ -27,7 +27,7 @@ abstract class SignatureMethod { /** * Verifies that a given signature is correct - * @param OAuthRequest $request + * @param Request $request * @param OAuthConsumer $consumer * @param OAuthToken $token * @param string $signature