Skip to content

Commit

Permalink
replaces withAPIData with withSelect from wp.data for API request/call
Browse files Browse the repository at this point in the history
  • Loading branch information
jomurgel committed Sep 21, 2018
1 parent 68c0e0c commit 20fa2e5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/search-edit-component/post-render.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
* WordPress dependencies
*/
const {
withAPIData,
} = wp.components;
withSelect,
} = wp.data;

const { Component } = wp.element;

Expand Down Expand Up @@ -87,7 +87,7 @@ class PostRenderer extends Component {
}
}

export default withAPIData( ( props ) => {
export default withSelect( ( props ) => {
const { posts } = props;

if ( undefined !== posts && '[]' !== posts ) {
Expand Down

0 comments on commit 20fa2e5

Please sign in to comment.