fix: unhandled exception for index not found in reflected types#45
fix: unhandled exception for index not found in reflected types#45yamishav wants to merge 3 commits into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #45 +/- ##
=======================================
Coverage 99.47% 99.48%
=======================================
Files 4 4
Lines 191 193 +2
Branches 58 59 +1
=======================================
+ Hits 190 192 +2
Misses 1 1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
epiphone
left a comment
There was a problem hiding this comment.
Thanks! Can you add a test case to demonstrate the error?
Also please run yarn format so that we get rid of the whitespace changes in the diff.
|
Hi, I updated the yarn format. |
|
Ok, I'll look into adding a test and getting this merged his week. |
|
any updates? |
|
Hi, Any chance we can move on with the PR? |
|
Okay, please revert the lock file deletion and we'll get this merged! |
|
The reason I'm a bit hesitant merging this is it's unclear to me whether this is something we should handle in the library or is this an edge case specific to your particular setup and thus better handled in your codebase. Hard to say without knowing the context or having a test! Then again it should be a pretty non-intrusive change so might as well go for it, I think. |
|
ok. I have reverted it |
|
Your previous commit added a bunch of |
Fix for:
On
const { explicitType, index, object, method } = param;
const type = Reflect.getMetadata('design:paramtypes', object, method)[index];
An error can be thrown if the index is not in the array;