parseFetchResponse = ( response, wpreq ) => {
	// Check if an HTTP error occurred.
	if ( ! response.ok ) {
		// Extract and return the API-provided error object if the response is
		// not ok, i.e. if the error was from the API and not internal to fetch.
		return response.json().then( ( err ) => {
			// Throw the error object to permit proper error handling.
			throw err;
		}, () => {
			// JSON serialization failed; throw the underlying response.
			throw response;
		} );
	}

	// If the response is OK, process & return the JSON data.
	return response.json().then( ( body ) => {
		// Construct a response the pagination helper can understand.
		const mockResponse = {
			headers: getHeaders( response ),
		};

		const _paging = createPaginationObject( mockResponse, wpreq._options, wpreq.transport );
		if ( _paging ) {
			body._paging = _paging;
		}
		return body;
	} );
}
Return the body of the request, augmented with pagination information if the
result is a paged collection.

@private
@param {WPRequest} wpreq The WPRequest representing the returned HTTP response
@param {Object} response The fetch response object for the HTTP call
@returns {Object} The JSON data of the response, conditionally augmented with
                  pagination information if the response is a partial collection.