Skip to content

Commit 83b7601

Browse files
authored
Pass this.props as well as nextProps to shouldRefetch
1 parent 0780c02 commit 83b7601

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/withStaticQuery.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export default function withStaticQueryContainer(config) {
1919

2020
if (!config.shouldRefetch) {
2121
this.fetch(query);
22-
} else if (config.shouldRefetch(nextProps)) {
22+
} else if (config.shouldRefetch(this.props, nextProps)) {
2323
this.fetch(query);
2424
}
2525
}

0 commit comments

Comments
 (0)