mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-23 10:09:40 +08:00
Merge pull request #6051 from anders-akero/patch-1
Update rest-error-handling.md
This commit is contained in:
@@ -77,7 +77,7 @@ return [
|
||||
'class' => 'yii\web\Response',
|
||||
'on beforeSend' => function ($event) {
|
||||
$response = $event->sender;
|
||||
if ($response->data !== null && !empty(Yii::$app->request->get['suppress_response_code'])) {
|
||||
if ($response->data !== null && !empty(Yii::$app->request->get('suppress_response_code'))) {
|
||||
$response->data = [
|
||||
'success' => $response->isSuccessful,
|
||||
'data' => $response->data,
|
||||
|
||||
Reference in New Issue
Block a user