Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I#5956 fix2 dont overwrite existing rpc settings #6044

Merged
merged 6 commits into from
Jan 29, 2019
Merged

Conversation

frankiebee
Copy link
Contributor

fixes #5956

@metamaskbot
Copy link
Collaborator

Builds ready [423f83e]: mascara, chrome, firefox, edge, opera

@bdresser
Copy link
Contributor

@frankiebee does this also fix #5934

const frequentRpcListDetail = this.preferencesController.getFrequentRpcListDetail()
const rpcSettings = frequentRpcListDetail.find((rpc) => rpcTarget === rpc.rpcUrl)

if (rpcSettings) {
Copy link
Contributor

@danjm danjm Jan 22, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this will break the ability to update an existing rpc url. I mean, currently if a user reenters the details of an rpc url, it will update that rpc url's data. I am note sure if we care about that, but this change will break that ability.

We could add an "updateCustomRpc" method that is called if a user enters an existing rpc url in the form on the settings page.

@danjm
Copy link
Contributor

danjm commented Jan 22, 2019

Code looks good and it does fix the linked issue. Sort of breaks another ability of the custom rpc form that might be used. We should either agree that it is okay to break that, or fix it in this PR.

@danfinlay
Copy link
Contributor

I don't think that has to block this, considering this fixes a pretty big issue, but I agree, it would be better if we never broke any behavior in the first place, and don't mind waiting an extra day or two for that. What do you think, @frankiebee?

@frankiebee
Copy link
Contributor Author

yeah i can get that in

@rstormsf
Copy link

Thanks everyone who is working on it. I highly appreciate it.

@frankiebee frankiebee added the DO-NOT-MERGE Pull requests that should not be merged label Jan 26, 2019
@frankiebee
Copy link
Contributor Author

adding the update function needs some more work

@frankiebee frankiebee removed the DO-NOT-MERGE Pull requests that should not be merged label Jan 28, 2019
@metamaskbot
Copy link
Collaborator

Builds ready [046abd3]: mascara, chrome, firefox, edge, opera

Copy link
Contributor

@danjm danjm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed code and QA'd. Looks good. Approved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Custom RPC incorrectly inserts chainId(4-rinkeby) eth_signTypedData_v3, signing tx affected.
6 participants