diff --git a/native/account/registration/avatar-selection.react.js b/native/account/registration/avatar-selection.react.js --- a/native/account/registration/avatar-selection.react.js +++ b/native/account/registration/avatar-selection.react.js @@ -34,7 +34,7 @@ export type AvatarSelectionParams = { +userSelections: { +coolOrNerdMode: CoolOrNerdMode, - +keyserverUsername: string, + +keyserverURL: string, +accountSelection: AccountSelection, }, }; diff --git a/native/account/registration/connect-ethereum.react.js b/native/account/registration/connect-ethereum.react.js --- a/native/account/registration/connect-ethereum.react.js +++ b/native/account/registration/connect-ethereum.react.js @@ -44,7 +44,7 @@ export type ConnectEthereumParams = { +userSelections: { +coolOrNerdMode: CoolOrNerdMode, - +keyserverUsername: string, + +keyserverURL: string, }, }; diff --git a/native/account/registration/keyserver-selection.react.js b/native/account/registration/keyserver-selection.react.js --- a/native/account/registration/keyserver-selection.react.js +++ b/native/account/registration/keyserver-selection.react.js @@ -56,18 +56,16 @@ invariant(registrationContext, 'registrationContext should be set'); const { cachedSelections, setCachedSelections } = registrationContext; - const initialKeyserverUsername = cachedSelections.keyserverUsername; + const initialKeyserverURL = cachedSelections.keyserverURL; const [customKeyserver, setCustomKeyserver] = React.useState( - initialKeyserverUsername === defaultURLPrefix - ? '' - : initialKeyserverUsername, + initialKeyserverURL === defaultURLPrefix ? '' : initialKeyserverURL, ); const customKeyserverTextInputRef = React.useRef(); let initialSelection; - if (initialKeyserverUsername === defaultURLPrefix) { + if (initialKeyserverURL === defaultURLPrefix) { initialSelection = 'ashoat'; - } else if (initialKeyserverUsername) { + } else if (initialKeyserverURL) { initialSelection = 'custom'; } @@ -88,24 +86,24 @@ setCurrentSelection('custom'); }, []); - let keyserverUsername; + let keyserverURL; if (currentSelection === 'ashoat') { - keyserverUsername = defaultURLPrefix; + keyserverURL = defaultURLPrefix; } else if (currentSelection === 'custom' && customKeyserver) { - keyserverUsername = customKeyserver; + keyserverURL = customKeyserver; } const versionLoadingStatus = useSelector(getVersionLoadingStatusSelector); - let buttonState = keyserverUsername ? 'enabled' : 'disabled'; + let buttonState = keyserverURL ? 'enabled' : 'disabled'; if (versionLoadingStatus === 'loading') { buttonState = 'loading'; } const serverCallParamOverride = React.useMemo( () => ({ - urlPrefix: keyserverUsername, + urlPrefix: keyserverURL, }), - [keyserverUsername], + [keyserverURL], ); const getVersionCall = useServerCall(getVersion, serverCallParamOverride); @@ -113,7 +111,7 @@ const { navigate } = props.navigation; const { coolOrNerdMode } = props.route.params.userSelections; const onSubmit = React.useCallback(async () => { - if (!keyserverUsername) { + if (!keyserverURL) { return; } @@ -125,16 +123,16 @@ setCachedSelections(oldUserSelections => ({ ...oldUserSelections, - keyserverUsername, + keyserverURL, })); navigate<'ConnectEthereum'>({ name: ConnectEthereumRouteName, - params: { userSelections: { coolOrNerdMode, keyserverUsername } }, + params: { userSelections: { coolOrNerdMode, keyserverURL } }, }); }, [ navigate, coolOrNerdMode, - keyserverUsername, + keyserverURL, setCachedSelections, dispatchActionPromise, getVersionCall, diff --git a/native/account/registration/password-selection.react.js b/native/account/registration/password-selection.react.js --- a/native/account/registration/password-selection.react.js +++ b/native/account/registration/password-selection.react.js @@ -24,7 +24,7 @@ export type PasswordSelectionParams = { +userSelections: { +coolOrNerdMode: CoolOrNerdMode, - +keyserverUsername: string, + +keyserverURL: string, +username: string, }, }; @@ -76,10 +76,10 @@ return; } - const { coolOrNerdMode, keyserverUsername, username } = userSelections; + const { coolOrNerdMode, keyserverURL, username } = userSelections; const newUserSelections = { coolOrNerdMode, - keyserverUsername, + keyserverURL, accountSelection: { accountType: 'username', username, diff --git a/native/account/registration/registration-terms.react.js b/native/account/registration/registration-terms.react.js --- a/native/account/registration/registration-terms.react.js +++ b/native/account/registration/registration-terms.react.js @@ -22,7 +22,7 @@ export type RegistrationTermsParams = { +userSelections: { +coolOrNerdMode: CoolOrNerdMode, - +keyserverUsername: string, + +keyserverURL: string, +accountSelection: AccountSelection, +avatarData: ?AvatarData, }, diff --git a/native/account/registration/registration-types.js b/native/account/registration/registration-types.js --- a/native/account/registration/registration-types.js +++ b/native/account/registration/registration-types.js @@ -39,14 +39,14 @@ export type RegistrationServerCallInput = { +coolOrNerdMode: CoolOrNerdMode, - +keyserverUsername: string, + +keyserverURL: string, +accountSelection: AccountSelection, +avatarData: ?AvatarData, }; export type CachedUserSelections = { +coolOrNerdMode?: CoolOrNerdMode, - +keyserverUsername?: string, + +keyserverURL?: string, +username?: string, +password?: string, +avatarData?: ?AvatarData, diff --git a/native/account/registration/username-selection.react.js b/native/account/registration/username-selection.react.js --- a/native/account/registration/username-selection.react.js +++ b/native/account/registration/username-selection.react.js @@ -37,7 +37,7 @@ export type UsernameSelectionParams = { +userSelections: { +coolOrNerdMode: CoolOrNerdMode, - +keyserverUsername: string, + +keyserverURL: string, }, };