Determine what type of request should be sent based on post fields
protected function processPostFields() {
if (empty($this->postFiles)) {
$this
->removeHeader('Expect')
->setHeader('Content-Type', self::URL_ENCODED);
}
else {
$this
->setHeader('Content-Type', self::MULTIPART);
if ($this->expectCutoff !== false) {
$this
->setHeader('Expect', '100-Continue');
}
}
}