mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-22 17:47:16 +00:00
I like destructuring
This commit is contained in:
parent
9dd5ccdd4e
commit
54606c8703
1 changed files with 2 additions and 2 deletions
|
|
@ -151,8 +151,8 @@ function findDirectDescendantById(node, id) {
|
|||
function findInLexicalScope(node, predicate) {
|
||||
let currentNode = node;
|
||||
while (currentNode.parent) {
|
||||
const parent = currentNode.parent;
|
||||
const children = parent.children;
|
||||
let { parent } = currentNode;
|
||||
const { children } = parent;
|
||||
for (let i = 0; i < children.length; i++) {
|
||||
const child = children[i];
|
||||
if (child === currentNode) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue