Skip to content

Instantly share code, notes, and snippets.

@jp1987
Created December 26, 2013 11:29
Show Gist options
  • Save jp1987/8132602 to your computer and use it in GitHub Desktop.
Save jp1987/8132602 to your computer and use it in GitHub Desktop.
protected function buildUnifiedArguments(array $getArguments, array $postArguments, array $uploadArguments) {
$arguments = $getArguments;
$contentArguments = NULL;
if ($this->method === 'POST') {
$contentArguments = ($postArguments !== array()) ? $postArguments : $this->decodeBodyArguments($this->getContent(), $this->headers->get('Content-Type'));
} elseif ($this->method === 'PUT') {
$contentArguments = $this->decodeBodyArguments($this->getContent(), $this->headers->get('Content-Type'));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment