mirror of
https://github.com/inventree/InvenTree.git
synced 2025-07-07 06:00:57 +00:00
fix(frontend): logic error in display of registration option (#9930)
* fix(frontend): logic error in display of registration option Fixes #9921 * simplify logic
This commit is contained in:
@ -40,8 +40,7 @@ export default function Login() {
|
|||||||
state.registration_enabled
|
state.registration_enabled
|
||||||
])
|
])
|
||||||
);
|
);
|
||||||
const both_reg_enabled =
|
const any_reg_enabled = registration_enabled() || sso_registration() || false;
|
||||||
registration_enabled() || sso_registration() || false;
|
|
||||||
|
|
||||||
const LoginMessage = useMemo(() => {
|
const LoginMessage = useMemo(() => {
|
||||||
const val = server.customize?.login_message;
|
const val = server.customize?.login_message;
|
||||||
@ -109,7 +108,7 @@ export default function Login() {
|
|||||||
) : (
|
) : (
|
||||||
<>
|
<>
|
||||||
<AuthenticationForm />
|
<AuthenticationForm />
|
||||||
{both_reg_enabled === false && (
|
{any_reg_enabled && (
|
||||||
<Text ta='center' size={'xs'} mt={'md'}>
|
<Text ta='center' size={'xs'} mt={'md'}>
|
||||||
<Trans>Don't have an account?</Trans>{' '}
|
<Trans>Don't have an account?</Trans>{' '}
|
||||||
<Anchor
|
<Anchor
|
||||||
|
Reference in New Issue
Block a user