Skip to content

Commit 9d48697

Browse files
feat: export token scan types (#7208)
## Explanation <!-- Thanks for your contribution! Take a moment to answer these questions so that reviewers have the information they need to properly understand your changes: * What is the current state of things and why does it need to change? * What is the solution your changes offer and how does it work? * Are there any changes whose purpose might not obvious to those unfamiliar with the domain? * If your primary goal was to update one package but you found you had to update another one along the way, why did you do so? * If you had to upgrade a dependency, why did you do so? --> Exports `TokenScanCacheData` and `TokenScanResultType` so that users of the PhishingController do not need to create their own types when accessing cache entries within the token scan cache. ## Checklist - [x] I've updated the test suite for new or updated code as appropriate - [x] I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate - [x] I've communicated my changes to consumers by [updating changelogs for packages I've changed](https://github.com/MetaMask/core/tree/main/docs/contributing.md#updating-changelogs), highlighting breaking changes as necessary - [ ] I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes <!-- CURSOR_SUMMARY --> --- > [!NOTE] > Exports `TokenScanCacheData` and `TokenScanResultType` from `src/index.ts` and documents the change in the changelog. > > - **phishing-controller** > - **Exports**: Add `TokenScanCacheData` and `TokenScanResultType` to public exports in `src/index.ts`. > - **Docs**: Update `CHANGELOG.md` under Unreleased to note these new exports. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit d7a587b. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
1 parent 7dda377 commit 9d48697

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

packages/phishing-controller/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
### Added
11+
12+
- Export `TokenScanCacheData` and `TokenScanResultType` to allow consumers to have a type to reference if grabbing values directly from the controller's state ([#7208](https://github.com/MetaMask/core/pull/7208))
13+
1014
## [16.0.0]
1115

1216
### Added

packages/phishing-controller/src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ export type {
88
} from './PhishingDetector';
99
export { PhishingDetector } from './PhishingDetector';
1010
export type { PhishingDetectionScanResult, AddressScanResult } from './types';
11+
export type { TokenScanCacheData, TokenScanResultType } from './types';
1112
export {
1213
PhishingDetectorResultType,
1314
RecommendedAction,

0 commit comments

Comments
 (0)