Merge pull request #2164 from pterodactyl/fix/2163
Fix 2FA codes missing prepended 0s
This commit is contained in:
commit
45a85938df
1 changed files with 2 additions and 1 deletions
|
@ -40,7 +40,7 @@ const LoginCheckpointContainer = () => {
|
||||||
? 'Enter one of the recovery codes generated when you setup 2-Factor authentication on this account in order to continue.'
|
? 'Enter one of the recovery codes generated when you setup 2-Factor authentication on this account in order to continue.'
|
||||||
: 'Enter the two-factor token generated by your device.'
|
: 'Enter the two-factor token generated by your device.'
|
||||||
}
|
}
|
||||||
type={isMissingDevice ? 'text' : 'number'}
|
type={'text'}
|
||||||
autoFocus
|
autoFocus
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
@ -81,6 +81,7 @@ const LoginCheckpointContainer = () => {
|
||||||
const EnhancedForm = withFormik<Props, Values>({
|
const EnhancedForm = withFormik<Props, Values>({
|
||||||
handleSubmit: ({ code, recoveryCode }, { setSubmitting, props: { addError, clearFlashes, location } }) => {
|
handleSubmit: ({ code, recoveryCode }, { setSubmitting, props: { addError, clearFlashes, location } }) => {
|
||||||
clearFlashes();
|
clearFlashes();
|
||||||
|
|
||||||
loginCheckpoint(location.state?.token || '', code, recoveryCode)
|
loginCheckpoint(location.state?.token || '', code, recoveryCode)
|
||||||
.then(response => {
|
.then(response => {
|
||||||
if (response.complete) {
|
if (response.complete) {
|
||||||
|
|
Loading…
Reference in a new issue