-
Notifications
You must be signed in to change notification settings - Fork 36
Description
webext-core/packages/messaging/src/generic.ts
Line 137 in 2720301
const err = Error( |
您好,我在使用消息通讯包的时候,遇到了点麻烦。
简而言之,公司的旧版本插件我在改造的过程中,一部分使用原有的 消息通讯方案,一部分使用了 @webext-core/proxy-service
, 显然他们的协议会有区别
我探索了源码,发现其实这里已经可以知道消息是否来自 @webext-core/proxy-service
,或许我们可以不抛出异常,直接 return
或者可选地抛出异常? 目前我打了个补丁,但是我希望这个提议可以被采纳,谢谢。
Hello, I'm having some trouble using the messaging package.
In short, during the process of modifying the old version plugins of the company, some of them used the original message communication scheme, while others used '@ webext core/proxy service'. Obviously, their protocols will be different
I have explored the source code and found that it is already possible to determine whether the message is from '@ webext core/proxy service'. Perhaps we can simply 'return' without throwing an exception, or alternatively throw an exception? I have currently applied a patch, but I hope this proposal can be accepted. Thank you.