mirror of
https://github.com/Mibew/tray.git
synced 2025-01-22 18:10:34 +03:00
Fix early return from RequestProcessor::processRequest
This commit is contained in:
parent
bebe603a9b
commit
c26fc8bb26
@ -139,14 +139,14 @@ abstract class RequestProcessor {
|
|||||||
? array()
|
? array()
|
||||||
: $callback['arguments'];
|
: $callback['arguments'];
|
||||||
call_user_func_array($function, array($arguments));
|
call_user_func_array($function, array($arguments));
|
||||||
return true;
|
continue;
|
||||||
} else {
|
} else {
|
||||||
// Try to get result function
|
// Try to get result function
|
||||||
$result_function = $this->mibewAPI->getResultFunction($request['functions']);
|
$result_function = $this->mibewAPI->getResultFunction($request['functions']);
|
||||||
|
|
||||||
if (! is_null($result_function)) {
|
if (! is_null($result_function)) {
|
||||||
// There is result function but no callback
|
// There is result function but no callback
|
||||||
return true;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// There is no result function
|
// There is no result function
|
||||||
@ -170,11 +170,14 @@ abstract class RequestProcessor {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (count($this->responses) != 0) {
|
||||||
|
// Send responses
|
||||||
if ($request_package['async']) {
|
if ($request_package['async']) {
|
||||||
$this->sendAsyncResponses($this->responses);
|
$this->sendAsyncResponses($this->responses);
|
||||||
} else {
|
} else {
|
||||||
$this->sendSyncResponses($this->responses);
|
$this->sendSyncResponses($this->responses);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Output response
|
// Output response
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user