Skip to content

Commit bc59998

Browse files
authored
perf: Remove unnecessary data fetches from data browser pagination (parse-community#3098)
1 parent 185e674 commit bc59998

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

src/dashboard/Data/Browser/Browser.react.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1419,10 +1419,6 @@ class Browser extends DashboardView {
14191419
// filters param change is making the fetch call
14201420
this.props.navigate(generatePath(this.context, url));
14211421
}
1422-
1423-
this.setState({
1424-
skip: 0,
1425-
});
14261422
}
14271423

14281424
async saveFilters(filters, name, relativeDate, filterId = null) {
@@ -2730,15 +2726,13 @@ class Browser extends DashboardView {
27302726
setSkip={skip => {
27312727
this.setState({ skip }, () => {
27322728
this.updateURL(skip, null);
2733-
this.updateOrdering(this.state.ordering);
27342729
});
27352730
}}
27362731
count={count}
27372732
limit={this.state.limit}
27382733
setLimit={limit => {
27392734
this.setState({ limit, skip: 0 }, () => {
2740-
this.updateURL(0, limit); // Reset to first page when limit changes
2741-
this.updateOrdering(this.state.ordering);
2735+
this.updateURL(0, limit);
27422736
});
27432737
}}
27442738
hasSelectedRows={Object.keys(this.state.selection).length > 0}

0 commit comments

Comments
 (0)