Skip to content
This repository has been archived by the owner on Feb 22, 2018. It is now read-only.

_getById handle unknown keys better #1331

Open
vsavkin opened this issue Aug 8, 2014 · 0 comments
Open

_getById handle unknown keys better #1331

vsavkin opened this issue Aug 8, 2014 · 0 comments

Comments

@vsavkin
Copy link
Contributor

vsavkin commented Aug 8, 2014

Right now when invoked with an unknown key, _getById will throw new NoProviderError(null), which is not very helpful.

_getById(int keyId) {
  //switch ....
  throw new NoProviderError(DirectiveInjector._KEYS[keyId]);
}

This can be improved by changing NoProviderError to include the keyId in addition to the key itself.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

2 participants