Skip to content

Commit

Permalink
fix: request all() not includes all payload attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
Bit-Code-Developer committed Oct 16, 2024
1 parent f222cf1 commit 9d214a2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Http/Request/Request.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,10 @@ public function setApiRequest(WP_REST_Request $request)
$this->setBody((array) $request->get_body_params() + (array) $request->get_json_params());
$this->setQueryParams((array) $request->get_query_params());
$this->setRouteParams((array) $request->get_url_params());
$this->attributes = (array) $request->get_params();
$this->rest = $request;

$this->attributes = (array) $this->queryParams + (array) $this->body + (array) $this->routeParams;

$this->rest = $request;
}

/**
Expand Down

0 comments on commit 9d214a2

Please sign in to comment.