public function JsResponse::__sleep in JS Callback Handler 8.3
File
- src/
JsResponse.php, line 46
Class
- JsResponse
- JsResponse.
Namespace
Drupal\jsCode
public function __sleep() {
$keys = $this
->__traitSleep();
// If a response is serialized, that means the content has already been
// constructed from the data. Because the data may contain objects that
// aren't serializable (way down in the render array), then it should just
// be removed entirely to avoid any container serializations.
return array_diff($keys, [
'data',
]);
}