Login:App:Confirrm: remove request colorTheme
This commit is contained in:
parent
25731566d9
commit
07ff333d4c
@ -24,18 +24,11 @@
|
||||
// content are licensed under the terms of the Creative Commons Attribution-ShareAlike 4.0
|
||||
// International. See the License terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
|
||||
import { getColorTheme, getSettings } from "@/utils/actions";
|
||||
import { getSettings } from "@/utils/actions";
|
||||
import ProfileRemoveForm from "@/components/ProfileRemoveForm ";
|
||||
|
||||
async function Page() {
|
||||
const [settings, colorTheme] = await Promise.all([
|
||||
getSettings(),
|
||||
getColorTheme(),
|
||||
]);
|
||||
|
||||
const currentColorScheme = colorTheme?.themes.find((theme) => {
|
||||
return colorTheme && colorTheme.selected === theme.id;
|
||||
});
|
||||
const settings = await getSettings();
|
||||
|
||||
return (
|
||||
<div className="content-center">
|
||||
@ -43,7 +36,6 @@ async function Page() {
|
||||
<ProfileRemoveForm
|
||||
greetingSettings={settings.greetingSettings}
|
||||
legalTerms={settings.legalTerms}
|
||||
currentColorScheme={currentColorScheme}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
|
@ -28,7 +28,6 @@ import TfaActivationForm from "@/components/TfaActivationForm";
|
||||
import { StyledForm } from "@/components/TfaActivationForm/TfaActivationForm.styled";
|
||||
import { getStringFromSearchParams } from "@/utils";
|
||||
import {
|
||||
getColorTheme,
|
||||
getSettings,
|
||||
getTfaSecretKeyAndQR,
|
||||
getUserFromConfirm,
|
||||
@ -39,12 +38,6 @@ type TfaActivationProps = {
|
||||
};
|
||||
|
||||
async function Page({ searchParams }: TfaActivationProps) {
|
||||
const colorTheme = await getColorTheme();
|
||||
|
||||
const currentColorScheme = colorTheme?.themes.find((theme) => {
|
||||
return colorTheme && colorTheme.selected === theme.id;
|
||||
});
|
||||
|
||||
const confirmKey = getStringFromSearchParams(searchParams);
|
||||
const uid = searchParams.uid;
|
||||
|
||||
@ -63,7 +56,6 @@ async function Page({ searchParams }: TfaActivationProps) {
|
||||
qrCode={res.qrCodeSetupImageUrl}
|
||||
passwordHash={settings?.passwordHash}
|
||||
userName={user?.userName}
|
||||
currentColorScheme={currentColorScheme}
|
||||
/>
|
||||
</StyledForm>
|
||||
)}
|
||||
|
Loading…
Reference in New Issue
Block a user