Skip to content

Commit

Permalink
fix: include 33b91a2 in the wire reform
Browse files Browse the repository at this point in the history
  • Loading branch information
jodarove committed Mar 23, 2020
1 parent 4a07eb4 commit 0158f39
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 1 addition & 6 deletions packages/@lwc/wire-service/src/__tests__/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ describe('WireEventTarget from register', () => {
expect(dataCallback.mock.calls[0][0]).toBe(expected);
});

it('should dispatchEvent in wiredComponent when dispatching event with type WireContextEvent or wirecontextevent', () => {
it('should dispatchEvent in wiredComponent when dispatching event with type wirecontextevent', () => {
const adapterId = {};
let wireEventTarget: WireEventTarget;
const dataCallback = jest.fn();
Expand All @@ -146,11 +146,6 @@ describe('WireEventTarget from register', () => {
register(adapterId, adapterFactory);
new adapterId.adapter(dataCallback);

const wireContextEvent = new CustomEvent('WireContextEvent', {
detail: {
foo: 'bar',
},
});
const wireContextEventInLowercase = new CustomEvent('wirecontextevent', {
detail: {
foo: 'bar',
Expand Down
2 changes: 1 addition & 1 deletion packages/@lwc/wire-service/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ export class WireAdapter {
if (evt instanceof ValueChangedEvent) {
const value = evt.value;
this.callback(value);
} else if (evt.type === 'WireContextEvent' || evt.type === 'wirecontextevent') {
} else if (evt.type === 'wirecontextevent') {
// TODO [#1357]: remove this branch
return this.wiredElementHost.dispatchEvent(evt);
} else {
Expand Down

0 comments on commit 0158f39

Please sign in to comment.