Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove redundant handler check in Bus #3669

Closed
yatki opened this issue May 20, 2019 · 0 comments
Closed

Remove redundant handler check in Bus #3669

yatki opened this issue May 20, 2019 · 0 comments

Comments

@yatki
Copy link
Contributor

yatki commented May 20, 2019

Expected behavior

Bus doesn't know about the handler of the action. So we shouldn't have that check in the bus.

Actual behavior

That check is actually causing false exceptions.

Object.keys(actions).forEach(actionName => {
const actionFullName = `${moduleAlias}:${actionName}`;
if (
typeof actions[actionName] !== 'object' ||
!actions[actionName].handler
) {
throw new Error(
`Action "${actionFullName}" should be object with handler property.`
);
}

Steps to reproduce

Which version(s) does this affect? (Environment, OS, etc...)

2.0.0

@yatki yatki self-assigned this May 20, 2019
shuse2 added a commit that referenced this issue May 21, 2019
Remove redundant handler check in Bus - Closes #3669
@shuse2 shuse2 closed this as completed May 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants