Changeset View
Changeset View
Standalone View
Standalone View
src/future/http/BaseHTTPFuture.php
Show First 20 Lines • Show All 267 Lines • ▼ Show 20 Lines | public function getHTTPRequestByteLength() { | ||||
// NOTE: This isn't very accurate, but it's only used by the "--trace" | // NOTE: This isn't very accurate, but it's only used by the "--trace" | ||||
// call profiler to help pick out huge requests. | // call profiler to help pick out huge requests. | ||||
$data = $this->getData(); | $data = $this->getData(); | ||||
if (is_scalar($data)) { | if (is_scalar($data)) { | ||||
return strlen($data); | return strlen($data); | ||||
} | } | ||||
return strlen(http_build_query($data, '', '&')); | return strlen(phutil_build_http_querystring($data)); | ||||
} | } | ||||
/* -( Resolving the Request )---------------------------------------------- */ | /* -( Resolving the Request )---------------------------------------------- */ | ||||
/** | /** | ||||
* Exception-oriented @{method:resolve}. Throws if the status indicates an | * Exception-oriented @{method:resolve}. Throws if the status indicates an | ||||
▲ Show 20 Lines • Show All 143 Lines • Show Last 20 Lines |