Skip to content

Commit 5a1db22

Browse files
committed
Fix loading message not showing when 10 new suggestions are retrieved
1 parent 8e4a4d6 commit 5a1db22

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/store/modules/tiles.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,14 @@ const actions = {
3535
},
3636

3737
getSuggestions({ state, rootState, rootGetters, commit }) {
38+
state.list = null;
3839
axios
3940
.get(
4041
`${rootState.LANGUAGETOOL_ENDPOINT_ROOT}/suggestions?` +
4142
rootGetters.languageWithAccessToken.join(",")
4243
)
4344
.then(({ data }) => {
44-
state.list = (state.list || []).concat(data.suggestions);
45+
state.list = data.suggestions;
4546
commit("setFirstAsActive");
4647
});
4748
},

0 commit comments

Comments
 (0)