p42ai / js-assistant

120+ refactorings and code-assists for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=p42ai.refactor
MIT License
119 stars 7 forks source link

Do not suggest destruction on optional chaining. #38

Closed lixiaoyan closed 1 year ago

lixiaoyan commented 1 year ago
const baz = window.foo?.bar.baz;

should not change to

const { baz } = window.foo?.bar;
lgrammel commented 1 year ago

@lixiaoyan thanks for the bug report! I just released v1.121.3, which fixes the bug. Please re-open this issue if you still encounter the bug in v1.121.3 or higher.