Commit 66e502c6 authored by Thomas Randolph's avatar Thomas Randolph

Rename app eventHub to correct notesEventHub

parent 775f9093
...@@ -10,7 +10,8 @@ import PanelResizer from '~/vue_shared/components/panel_resizer.vue'; ...@@ -10,7 +10,8 @@ import PanelResizer from '~/vue_shared/components/panel_resizer.vue';
import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin'; import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
import { isSingleViewStyle } from '~/helpers/diffs_helper'; import { isSingleViewStyle } from '~/helpers/diffs_helper';
import { updateHistory } from '~/lib/utils/url_utility'; import { updateHistory } from '~/lib/utils/url_utility';
import eventHub from '../../notes/event_hub';
import notesEventHub from '../../notes/event_hub';
import CompareVersions from './compare_versions.vue'; import CompareVersions from './compare_versions.vue';
import DiffFile from './diff_file.vue'; import DiffFile from './diff_file.vue';
import NoChanges from './no_changes.vue'; import NoChanges from './no_changes.vue';
...@@ -280,8 +281,8 @@ export default { ...@@ -280,8 +281,8 @@ export default {
created() { created() {
this.adjustView(); this.adjustView();
eventHub.$once('fetchDiffData', this.fetchData); notesEventHub.$once('fetchDiffData', this.fetchData);
eventHub.$on('refetchDiffData', this.refetchDiffData); notesEventHub.$on('refetchDiffData', this.refetchDiffData);
this.CENTERED_LIMITED_CONTAINER_CLASSES = CENTERED_LIMITED_CONTAINER_CLASSES; this.CENTERED_LIMITED_CONTAINER_CLASSES = CENTERED_LIMITED_CONTAINER_CLASSES;
this.unwatchDiscussions = this.$watch( this.unwatchDiscussions = this.$watch(
...@@ -302,8 +303,9 @@ export default { ...@@ -302,8 +303,9 @@ export default {
beforeDestroy() { beforeDestroy() {
diffsApp.deinstrument(); diffsApp.deinstrument();
eventHub.$off('fetchDiffData', this.fetchData); notesEventHub.$off('refetchDiffData', this.refetchDiffData);
eventHub.$off('refetchDiffData', this.refetchDiffData); notesEventHub.$off('fetchDiffData', this.fetchData);
this.removeEventListeners(); this.removeEventListeners();
}, },
methods: { methods: {
...@@ -373,7 +375,7 @@ export default { ...@@ -373,7 +375,7 @@ export default {
} }
if (!this.isNotesFetched) { if (!this.isNotesFetched) {
eventHub.$emit('fetchNotesData'); notesEventHub.$emit('fetchNotesData');
} }
}, },
setDiscussions() { setDiscussions() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment