diff options
author | Phil Hughes <me@iamphill.com> | 2018-09-17 09:49:52 +0100 |
---|---|---|
committer | André Luís <aluis@gitlab.com> | 2018-09-21 11:59:44 +0100 |
commit | e3cc9d53d2fb69be8a79daacaecb28d45280880a (patch) | |
tree | 73bdd4a0791b6104282e88df4ebdcd15f5364fb4 /app | |
parent | 2497c29ef0d1e178c8b3aa96e8304ee6765bae4e (diff) | |
download | gitlab-ce-e3cc9d53d2fb69be8a79daacaecb28d45280880a.tar.gz |
Fixed karma spec for getNoteFormData
Fixed toggling new notes caused by not returning the stores discussion
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/notes/stores/actions.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/assets/javascripts/notes/stores/actions.js b/app/assets/javascripts/notes/stores/actions.js index 62b36f300ff..320dfa47d5a 100644 --- a/app/assets/javascripts/notes/stores/actions.js +++ b/app/assets/javascripts/notes/stores/actions.js @@ -44,10 +44,10 @@ export const fetchDiscussions = ({ commit }, path) => commit(types.SET_INITIAL_DISCUSSIONS, discussions); }); -export const updateDiscussion = ({ commit }, discussion) => { +export const updateDiscussion = ({ commit, state }, discussion) => { commit(types.UPDATE_DISCUSSION, discussion); - return discussion; + return utils.findNoteObjectById(state.discussions, discussion.id); }; export const deleteNote = ({ commit, dispatch }, note) => |