Skip to content

Commit 2219e0d

Browse files
committed
address feedback
1 parent 4b9313f commit 2219e0d

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

app/scripts/controllers/mmi-controller.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -791,8 +791,10 @@ export default class MMIController extends EventEmitter {
791791
const updatedMsgParams = { ...msgParams, deferSetAsSigned: isCustodial };
792792

793793
if (
794-
!req.method.includes('eth_signTypedData') &&
795-
!req.method.includes('personal_sign')
794+
req.method !== 'eth_signTypedData' &&
795+
req.method !== 'eth_signTypedData_v3' &&
796+
req.method !== 'eth_signTypedData_v4' &&
797+
req.method !== 'personal_sign'
796798
) {
797799
throw new Error('Unexpected method');
798800
}
@@ -804,7 +806,7 @@ export default class MMIController extends EventEmitter {
804806
version,
805807
{ parseJsonData: false },
806808
);
807-
} else if (req.method.includes('personal_sign')) {
809+
} else if (req.method === 'personal_sign') {
808810
return await this.signatureController.newUnsignedPersonalMessage(
809811
updatedMsgParams as PersonalMessageParams,
810812
req as OriginalRequest,

app/scripts/metamask-controller.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1798,7 +1798,8 @@ export default class MetamaskController extends EventEmitter {
17981798
`${this.loggingController.name}:add`,
17991799
],
18001800
}),
1801-
isEthSignEnabled: false,
1801+
// TODO remove this option
1802+
isEthSignEnabled: () => false,
18021803
getAllState: this.getState.bind(this),
18031804
getCurrentChainId: () =>
18041805
this.networkController.state.providerConfig.chainId,

0 commit comments

Comments
 (0)