aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-07-24 09:20:27 +0000
committermarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-07-24 09:20:27 +0000
commit3a0cc3d3bc98dcec20b879e1205f72d971a66233 (patch)
treee6102b248a3ee4a6931649a90d06530e6827cc98
parentcc9eba54622e8eac3f0abb5c6d5c9a43b3a8c8d1 (diff)
downloadelgg-3a0cc3d3bc98dcec20b879e1205f72d971a66233.tar.gz
elgg-3a0cc3d3bc98dcec20b879e1205f72d971a66233.tar.bz2
Api tweaks refs #149
git-svn-id: https://code.elgg.org/elgg/trunk@1508 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r--engine/lib/api.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/engine/lib/api.php b/engine/lib/api.php
index ca8d559d8..ed77fe162 100644
--- a/engine/lib/api.php
+++ b/engine/lib/api.php
@@ -761,10 +761,11 @@
$headers = array();
$encoded_params = array();
+ $method = strtoupper($method);
switch (strtoupper($method))
{
case 'GET' :
- case 'POST' : $method = strtoupper($method); break;
+ case 'POST' : break;
default: throw new NotImplementedException(sprintf(elgg_echo('NotImplementedException:CallMethodNotImplemented'), $method));
}
@@ -847,7 +848,7 @@
* @param string $content_type The content type
* @return stdClass The unserialised response object
*/
- function send_api_post_call($url, array $call, array $keys, $post_data, $content_type = 'application/octet-stream') { return send_api_call($url, $call, 'POST', $post_data, $content_type); }
+ function send_api_post_call($url, array $call, array $keys, $post_data, $content_type = 'application/octet-stream') { return send_api_call($keys, $url, $call, 'POST', $post_data, $content_type); }
/**
* Return a key array suitable for the API client using the standard authentication method based on api-keys and secret keys.