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

[TRAH] shontzu/TRAH-2643/MT5PasswordModal-improvement #24

Conversation

shontzu-deriv
Copy link
Owner

@shontzu-deriv shontzu-deriv commented Jan 12, 2024

Changes:

  • CU
    split massive MT5PasswordModal file into smaller components

Screenshots:

image

@shontzu-deriv shontzu-deriv force-pushed the shontzu/TRAH-2643/MT5PasswordModal-improvement-3 branch from 00cb0a4 to 6882623 Compare January 12, 2024 05:34
@shontzu-deriv shontzu-deriv self-assigned this Jan 12, 2024
password,
marketType,
activeTrading,
mutate,

Choose a reason for hiding this comment

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

tradingPasswordChange,
mutate,
activeTrading,
settings,

These are coming from deriv/api so we can directly call them here instead of passing props

selectedJurisdiction,
availableMT5Accounts
) => {
const accountType = marketType === MarketType.SYNTHETIC ? 'gaming' : marketType;

Choose a reason for hiding this comment

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

Can use constant file here for gaming but its upto you
Its a small nit but it is hardcoded value


// in order to create account, we need to set a password through trading_platform_password_change endpoint first
// then only mt5_create_account can be called, otherwise it will response an error for password required
if (isMT5PasswordNotSet) {

Choose a reason for hiding this comment

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

can get this from deriv/api

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.

2 participants