Skip to content

Commit 65a9c08

Browse files
committed
Merge remote-tracking branch 'origin/mikesposito/messenger/polling-controllers' into mikesposito/messenger/assets-controllers
* origin/mikesposito/messenger/polling-controllers: Update ESLint warning threshold Fix changelog mistakes from recent merges Update changelogs following branch update Update messagingSystem references to messenger
2 parents e46206b + 9660de8 commit 65a9c08

File tree

8 files changed

+40
-28
lines changed

8 files changed

+40
-28
lines changed

packages/approval-controller/CHANGELOG.md

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

88
## [Unreleased]
99

10+
### Changed
11+
12+
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
13+
- Previously, `ApprovalController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
14+
1015
## [7.2.1]
1116

1217
### Changed
@@ -21,8 +26,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2126

2227
### Changed
2328

24-
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
25-
- Previously, `ApprovalController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
2629
- Bump `@metamask/utils` from `^11.2.0` to `^11.8.1` ([#6054](https://github.com/MetaMask/core/pull/6054), [#6588](https://github.com/MetaMask/core/pull/6588), [#6708](https://github.com/MetaMask/core/pull/6708))
2730
- Bump `@metamask/base-controller` from `^8.0.0` to `^8.4.1` ([#5722](https://github.com/MetaMask/core/pull/5722), [#6284](https://github.com/MetaMask/core/pull/6284), [#6355](https://github.com/MetaMask/core/pull/6355), [#6465](https://github.com/MetaMask/core/pull/6465), [#6632](https://github.com/MetaMask/core/pull/6632), [#6807](https://github.com/MetaMask/core/pull/6807))
2831

packages/assets-controllers/CHANGELOG.md

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

88
## [Unreleased]
99

10+
### Added
11+
12+
- Add export for `CurrencyRateMessenger` ([#6444](https://github.com/MetaMask/core/pull/6444))
13+
1014
### Changed
1115

16+
- **BREAKING:** Migrate controllers to new `Messenger` from `@metamask/messenger` ([#6444](https://github.com/MetaMask/core/pull/6444), [#6386](https://github.com/MetaMask/core/pull/6386), [#6745](https://github.com/MetaMask/core/pull/6745))
17+
- Previously, the controllers accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
1218
- Bump `@metamask/polling-controller` from `^14.0.1` to `^14.0.2` ([#6940](https://github.com/MetaMask/core/pull/6940))
1319

1420
## [83.1.0]
@@ -38,16 +44,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3844
### Added
3945

4046
- **BREAKING:** Add new event listeners to refresh balances on `TransactionControllerUnapprovedTransactionAddedEvent` and `TransactionControllerTransactionConfirmedEvent` ([#6903](https://github.com/MetaMask/core/pull/6903))
41-
- Add export for `CurrencyRateMessenger` ([#6444](https://github.com/MetaMask/core/pull/6444))
4247
- Add multicall addresses in `MULTICALL_CONTRACT_BY_CHAINID` ([#6896](https://github.com/MetaMask/core/pull/6896))
4348
- Add multicall address for Chains: `Injective`, `Hemi`, `Plasma`, `Nonmia`, `XRPL`, `Soneium`, `Genesys`, `EDU`, `Abstract`, `Berachain`, `MegaETH Testnet`, `Apechain`, `Matchain`, `Monad Testnet`, `Monad`, `Katana`, `Lens`, `Plume`, `XDC`
4449

4550
### Changed
4651

47-
- **BREAKING:** Migrate controllers to new `Messenger` from `@metamask/messenger` ([#6444](https://github.com/MetaMask/core/pull/6444), [#6386](https://github.com/MetaMask/core/pull/6386), [#6745](https://github.com/MetaMask/core/pull/6745))
48-
- Previously, the controllers accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
49-
- Add multicall addresses in `MULTICALL_CONTRACT_BY_CHAINID` ([#6896](https://github.com/MetaMask/core/pull/6896))
50-
- Add multicall address for Chains: `Injective`, `Hemi`, `Plasma`, `Nonmia`, `XRPL`, `Soneium`, `Genesys`, `EDU`, `Abstract`, `Berachain`, `MegaETH Testnet`, `Apechain`, `Matchain`, `Monad Testnet`, `Monad`, `Katana`, `Lens`, `Plume`, `XDC`
5152
- Batch `OnAssetConversion` and `OnAssetsMarketData` requests to non-EVM account Snaps ([#6886](https://github.com/MetaMask/core/pull/6886))
5253

5354
## [81.0.1]

packages/bridge-status-controller/CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99

1010
### Changed
1111

12+
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6444](https://github.com/MetaMask/core/pull/6444))
13+
- Previously, `BridgeStatusController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
1214
- Bump `@metamask/polling-controller` from `^14.0.1` to `^14.0.2` ([#6940](https://github.com/MetaMask/core/pull/6940))
1315

1416
## [55.0.0]
@@ -34,8 +36,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3436

3537
### Changed
3638

37-
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6444](https://github.com/MetaMask/core/pull/6444))
38-
- Previously, `BridgeStatusController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
3939
- Publish `destinationTransactionCompleted` event when a bridge tx completes on the destination chain ([#6900](https://github.com/MetaMask/core/pull/6900))
4040

4141
## [52.0.0]

packages/gas-fee-controller/CHANGELOG.md

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

88
## [Unreleased]
99

10+
### Added
11+
12+
- Export `GasFeeMessenger` type ([#6386](https://github.com/MetaMask/core/pull/6386), [#6444](https://github.com/MetaMask/core/pull/6444))
13+
14+
### Changed
15+
16+
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
17+
- Previously, `GasFeeController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
18+
1019
## [24.1.1]
1120

1221
### Changed
@@ -20,12 +29,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2029
### Added
2130

2231
- Add two new controller state metadata properties: `includeInStateLogs` and `usedInUi` ([#6473](https://github.com/MetaMask/core/pull/6473))
23-
- Export `GasFeeMessenger` type ([#6386](https://github.com/MetaMask/core/pull/6386), [#6444](https://github.com/MetaMask/core/pull/6444))
2432

2533
### Changed
2634

27-
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
28-
- Previously, `GasFeeController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
2935
- Bump `@metamask/base-controller` from `^8.0.1` to `^8.4.1` ([#6284](https://github.com/MetaMask/core/pull/6284), [#6355](https://github.com/MetaMask/core/pull/6355), [#6465](https://github.com/MetaMask/core/pull/6465), [#6632](https://github.com/MetaMask/core/pull/6632), [#6807](https://github.com/MetaMask/core/pull/6807))
3036
- Bump `@metamask/controller-utils` from `^11.10.0` to `^11.14.1` ([#6069](https://github.com/MetaMask/core/pull/6069), [#6303](https://github.com/MetaMask/core/pull/6303), [#6620](https://github.com/MetaMask/core/pull/6620), [#6629](https://github.com/MetaMask/core/pull/6629), [#6807](https://github.com/MetaMask/core/pull/6807))
3137
- Bump `@metamask/utils` from `^11.2.0` to `^11.8.1` ([#6054](https://github.com/MetaMask/core/pull/6054), [#6588](https://github.com/MetaMask/core/pull/6588), [#6708](https://github.com/MetaMask/core/pull/6708))

packages/network-controller/CHANGELOG.md

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

88
## [Unreleased]
99

10-
## [24.3.1]
11-
1210
### Changed
1311

1412
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
1513
- Previously, `NetworkController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
14+
15+
## [24.3.1]
16+
17+
### Changed
18+
1619
- Bump `@metamask/base-controller` from `^8.4.1` to `^8.4.2` ([#6917](https://github.com/MetaMask/core/pull/6917))
1720

1821
## [24.3.0]

packages/subscription-controller/CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99

1010
### Changed
1111

12+
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6444](https://github.com/MetaMask/core/pull/6444))
13+
- Previously, `SubscriptionController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
1214
- Bump `@metamask/polling-controller` from `^14.0.1` to `^14.0.2` ([#6940](https://github.com/MetaMask/core/pull/6940))
1315

1416
## [2.1.0]
1517

1618
### Changed
1719

18-
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6444](https://github.com/MetaMask/core/pull/6444))
19-
- Previously, `SubscriptionController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
2020
- Make `getCryptoApproveTransactionParams` synchronous ([#6930](https://github.com/MetaMask/core/pull/6930))
2121
- Bump `@metamask/base-controller` from `^8.4.1` to `^8.4.2` ([#6917](https://github.com/MetaMask/core/pull/6917))
2222

packages/transaction-controller/CHANGELOG.md

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

88
## [Unreleased]
99

10+
### Changed
11+
12+
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
13+
- Previously, `TransactionController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
14+
1015
## [60.10.0]
1116

1217
### Added
@@ -48,11 +53,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
4853

4954
- Add `txMeta` property to `GetSimulationConfig` callback ([#6833](https://github.com/MetaMask/core/pull/6833))
5055

51-
### Changed
52-
53-
- **BREAKING:** Use new `Messenger` from `@metamask/messenger` ([#6386](https://github.com/MetaMask/core/pull/6386))
54-
- Previously, `TransactionController` accepted a `RestrictedMessenger` instance from `@metamask/base-controller`.
55-
5656
## [60.6.1]
5757

5858
### Changed

packages/transaction-controller/src/TransactionController.ts

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2816,11 +2816,11 @@ export class TransactionController extends BaseController<
28162816
}
28172817

28182818
if (transactionMeta.type === TransactionType.swap) {
2819-
this.messagingSystem.publish('TransactionController:transactionNewSwap', {
2819+
this.messenger.publish('TransactionController:transactionNewSwap', {
28202820
transactionMeta,
28212821
});
28222822
} else if (transactionMeta.type === TransactionType.swapApproval) {
2823-
this.messagingSystem.publish(
2823+
this.messenger.publish(
28242824
'TransactionController:transactionNewSwapApproval',
28252825
{ transactionMeta },
28262826
);
@@ -2837,7 +2837,7 @@ export class TransactionController extends BaseController<
28372837
...transactionMeta,
28382838
txParams: {
28392839
...transactionMeta.txParams,
2840-
from: this.messagingSystem.call('AccountsController:getSelectedAccount')
2840+
from: this.messenger.call('AccountsController:getSelectedAccount')
28412841
.address,
28422842
},
28432843
};
@@ -2857,10 +2857,9 @@ export class TransactionController extends BaseController<
28572857
'Generated from user operation',
28582858
);
28592859

2860-
this.messagingSystem.publish(
2861-
'TransactionController:transactionStatusUpdated',
2862-
{ transactionMeta: updatedTransactionMeta },
2863-
);
2860+
this.messenger.publish('TransactionController:transactionStatusUpdated', {
2861+
transactionMeta: updatedTransactionMeta,
2862+
});
28642863
}
28652864

28662865
#addMetadata(transactionMeta: TransactionMeta) {

0 commit comments

Comments
 (0)