summaryrefslogtreecommitdiff
path: root/components/login
diff options
context:
space:
mode:
Diffstat (limited to 'components/login')
-rw-r--r--components/login/reset-password.tsx7
1 files changed, 5 insertions, 2 deletions
diff --git a/components/login/reset-password.tsx b/components/login/reset-password.tsx
index cc09f4fb..3846de79 100644
--- a/components/login/reset-password.tsx
+++ b/components/login/reset-password.tsx
@@ -12,6 +12,7 @@ import SuccessPage from './SuccessPage';
import { PasswordPolicy } from '@/lib/users/auth/passwordUtil';
import { PasswordValidationResult, resetPasswordAction, validatePasswordAction } from '@/lib/users/auth/partners-auth';
import { useTranslation } from '@/i18n/client';
+import { useParams } from 'next/navigation';
interface PasswordRequirement {
text: string;
@@ -23,10 +24,12 @@ interface Props {
token: string;
userId: number;
passwordPolicy: PasswordPolicy;
- lng?: string;
}
-export default function ResetPasswordForm({ token, userId, passwordPolicy, lng = 'ko' }: Props) {
+export default function ResetPasswordForm({ token, userId, passwordPolicy }: Props) {
+ const params = useParams() || {};
+ const lng = params.lng as string;
+
const { toast } = useToast();
const { t } = useTranslation(lng, 'login');