Skip to content

Commit 4fbd87b

Browse files
committed
Fix beforeFilter example
Refs cakephp/cakephp#18357
1 parent 0f6bbe0 commit 4fbd87b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

en/controllers/request-response.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1179,8 +1179,8 @@ Here are some common CORS configurations:
11791179
->allowCredentials()
11801180
->maxAge(86400)
11811181
->build();
1182-
1183-
return $this->response;
1182+
1183+
$event->setResult($this->response);
11841184
}
11851185
}
11861186

@@ -1233,7 +1233,7 @@ For consistent CORS handling across your application, create a middleware::
12331233
->allowCredentials()
12341234
->maxAge(3600)
12351235
->build();
1236-
1236+
12371237
return $response;
12381238
}
12391239

0 commit comments

Comments
 (0)