(node)
| 236 | |
| 237 | return { |
| 238 | VariableDeclarator(node) { |
| 239 | if (isInternalCryptoKeysRequire(node.init)) { |
| 240 | if (node.id.type === 'Identifier') { |
| 241 | namespaceNames.add(node.id.name); |
| 242 | return; |
| 243 | } |
| 244 | |
| 245 | if (node.id.type !== 'ObjectPattern') return; |
| 246 | |
| 247 | for (const property of node.id.properties) { |
| 248 | if (property.type !== 'Property') continue; |
| 249 | const keyName = property.key.name ?? property.key.value; |
| 250 | if (property.value.type !== 'Identifier') continue; |
| 251 | const localName = property.value.name; |
| 252 | if (keyName === 'isKeyObject') { |
| 253 | isKeyObjectNames.add(localName); |
| 254 | } else if (keyObjectClassNames.has(keyName)) { |
| 255 | knownKeyObjectClassNames.add(localName); |
| 256 | } |
| 257 | } |
| 258 | return; |
| 259 | } |
| 260 | |
| 261 | if (node.id.type === 'Identifier' && isKeyObjectFactory(node.init)) { |
| 262 | knownKeyObjectNames.add(node.id.name); |
| 263 | } |
| 264 | }, |
| 265 | |
| 266 | MemberExpression(node) { |
| 267 | const property = getPropertyName(node); |
nothing calls this directly
no test coverage detected