Closed ondratra closed 5 years ago
Have you tried 7.4.9 ?
Yes, sry I haven't mentioned it right away. Does it work for you?
We're seeing a similar error in 7.4.9 where Boom is undefined when we import is as such:
import Boom from '@hapi/boom';
Boom.isBoom(error)
The actual runtime error is: Cannot read property 'isBoom' of undefined
Update: it looks like the commit that caused my above issue is https://github.com/hapijs/boom/commit/feb25bfe1d4bee6324f62f43c49af072e148d170 by @hueniverse
cc'ing @el-besto
This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions.
Hi, in version
@hapi/boom v7.4.2
I was able to extend Boom class like this:and use my custom error in the project. But after version
7.4.3
it can't be done anymore. First of all I need toimport
in a slightly different way and then I get error. So in7.4.3
with this codeI get error
TypeError: Object prototype may only be an Object or null: undefined
Is it bug or intended feature? If so how to achieve the same effect?