Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/diffs/store/actions.js')
-rw-r--r--app/assets/javascripts/diffs/store/actions.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/app/assets/javascripts/diffs/store/actions.js b/app/assets/javascripts/diffs/store/actions.js
index 6714f4e62b8..b920e041135 100644
--- a/app/assets/javascripts/diffs/store/actions.js
+++ b/app/assets/javascripts/diffs/store/actions.js
@@ -64,6 +64,7 @@ export const fetchDiffFiles = ({ state, commit }) => {
const urlParams = {
w: state.showWhitespace ? '0' : '1',
};
+ let returnData;
if (state.useSingleDiffStyle) {
urlParams.view = state.diffViewType;
@@ -87,9 +88,13 @@ export const fetchDiffFiles = ({ state, commit }) => {
worker.postMessage(state.diffFiles);
+ returnData = res.data;
return Vue.nextTick();
})
- .then(handleLocationHash)
+ .then(() => {
+ handleLocationHash();
+ return returnData;
+ })
.catch(() => worker.terminate());
};
@@ -147,6 +152,7 @@ export const fetchDiffFilesMeta = ({ commit, state }) => {
prepareDiffData(data);
worker.postMessage(data.diff_files);
+ return data;
})
.catch(() => worker.terminate());
};