/* Generic exception class
*/
-class OAuthException extends Exception {
- // pass
+if (!class_exists('OAuthException')) {
+ class OAuthException extends Exception {
+ // pass
+ }
}
class OAuthConsumer {
/**
* builds the data one would send in a POST request
*/
- public function to_postdata() {
- return OAuthUtil::build_http_query($this->parameters);
+ public function to_postdata($raw = false) {
+ if ($raw)
+ return($this->parameters);
+ else
+ return OAuthUtil::build_http_query($this->parameters);
}
/**