Commit 3e1f672d authored by Doug Stull's avatar Doug Stull Committed by Andrew Fontaine

Remove inviteeType from invite modal triggers

- no longer needed as the option was removed.
parent eebbb1c7
......@@ -46,7 +46,6 @@ export default {
},
openModal() {
eventHub.$emit('openModal', {
inviteeType: 'members',
source: this.$options.openModalSource,
});
this.track(this.$options.buttonClickEvent);
......
......@@ -71,7 +71,7 @@ export default {
return this.triggerElement === targetTriggerElement;
},
openModal() {
eventHub.$emit('openModal', { inviteeType: 'members', source: this.triggerSource });
eventHub.$emit('openModal', { source: this.triggerSource });
},
},
TRIGGER_ELEMENT_BUTTON,
......
......@@ -72,7 +72,7 @@ export default {
return value;
},
openInviteMembersModal(mode) {
eventHub.$emit('openModal', { mode, inviteeType: 'members', source: 'learn-gitlab' });
eventHub.$emit('openModal', { mode, source: 'learn-gitlab' });
},
handleShowSuccessfulInvitationsAlert() {
this.showSuccessfulInvitationsAlert = true;
......
......@@ -37,11 +37,7 @@ export default {
},
methods: {
openModal() {
eventHub.$emit('openModal', {
inviteeType: 'members',
source: 'learn_gitlab',
tasksToBeDoneEnabled: true,
});
eventHub.$emit('openModal', { source: 'learn_gitlab' });
},
},
};
......
......@@ -76,7 +76,6 @@ describe('InviteMembersBanner', () => {
it('calls openModal through the eventHub', () => {
expect(eventHub.$emit).toHaveBeenCalledWith('openModal', {
inviteeType: 'members',
source: 'invite_members_banner',
});
});
......
......@@ -694,7 +694,7 @@ describe('InviteMembersModal', () => {
});
it('tracks the view for learn_gitlab source', () => {
eventHub.$emit('openModal', { inviteeType: 'members', source: LEARN_GITLAB });
eventHub.$emit('openModal', { source: LEARN_GITLAB });
expect(ExperimentTracking).toHaveBeenCalledWith(INVITE_MEMBERS_FOR_TASK.name);
expect(ExperimentTracking.prototype.event).toHaveBeenCalledWith(LEARN_GITLAB);
......
......@@ -71,7 +71,6 @@ describe.each(triggerItems)('with triggerElement as %s', (triggerItem) => {
findButton().vm.$emit('click');
expect(spy).toHaveBeenCalledWith('openModal', {
inviteeType: 'members',
source: triggerSource,
});
});
......
......@@ -114,11 +114,7 @@ describe('Learn GitLab Section Link', () => {
it('calls the eventHub', () => {
openInviteMembesrModalLink().vm.$emit('click');
expect(eventHub.$emit).toHaveBeenCalledWith('openModal', {
inviteeType: 'members',
source: 'learn_gitlab',
tasksToBeDoneEnabled: true,
});
expect(eventHub.$emit).toHaveBeenCalledWith('openModal', { source: 'learn_gitlab' });
});
it('tracks the click', async () => {
......
......@@ -80,7 +80,6 @@ describe('Learn GitLab', () => {
expect(spy).toHaveBeenCalledWith('openModal', {
mode: 'celebrate',
inviteeType: 'members',
source: 'learn-gitlab',
});
expect(cookieSpy).toHaveBeenCalledWith(INVITE_MODAL_OPEN_COOKIE);
......
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