Clean up resolveIndexedAccessMethod#8936
Merged
cryptodev-2s merged 2 commits intoMay 29, 2026
Merged
Conversation
This function still contains `istanbul ignore` comments. Most of these are unnecessary, and the logic actually ought to be tested. This commit cleans up these `istanbul ignore` comments, and also adds new ones to clarify the existing logic. It also renames `resolveIndexedAccessMethod` to `findClassMethodDeclaration` so that it's easier to understand the purpose of this method at a glance.
cryptodev-2s
approved these changes
May 29, 2026
8b0482f
into
feat/messenger-docs-site
375 of 376 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Explanation
resolveIndexedAccessMethodstill containsistanbul ignorecomments. Most of these are unnecessary, and the logic actually ought to be tested.This commit cleans up these
istanbul ignorecomments, and also adds new ones to clarify the existing logic. It also renamesresolveIndexedAccessMethodtofindClassMethodDeclarationso that it's easier to understand the purpose of this function at a glance.References
Checklist
Note
Low Risk
Documentation extraction only; behavior is clarified and covered by new tests, with no runtime product surface change.
Overview
Refactors messenger action handler resolution in
platform-api-docsextraction:resolveIndexedAccessMethodis renamed tofindClassMethodDeclaration, with clearer guards, inline examples, and removal ofistanbul ignorecoverage skips on paths that are now meant to run in production.Adds five tests that assert when
Class['method']cannot be resolved (object-literal type,keyof, numeric index, namespace-qualified class, missing method), docs still show the raw handler type text instead of failing or inventing a signature. Successful resolution behavior is unchanged; only naming, comments, and test coverage for fallbacks differ.Reviewed by Cursor Bugbot for commit 561b1c6. Bugbot is set up for automated code reviews on this repo. Configure here.