diff --git a/src/pages/profile.tsx b/src/pages/profile.tsx index 52a20db3..12806fbb 100644 --- a/src/pages/profile.tsx +++ b/src/pages/profile.tsx @@ -82,7 +82,7 @@ function UserProfile({user, mutateUser}: Props) { const [commercialRegistration, setCommercialRegistration] = useState( user.type === "agent" ? user.agentInformation?.commercialRegistration : undefined, ); - const [timezone, setTimezone] = useState(user.demographicInformation?.timezone || 'UTC'); + const [timezone, setTimezone] = useState(user.demographicInformation?.timezone || "UTC"); const {groups} = useGroups(); const {users} = useUsers(); @@ -248,7 +248,7 @@ function UserProfile({user, mutateUser}: Props) { ); const TimezoneInput = () => ( -
+
@@ -293,27 +293,29 @@ function UserProfile({user, mutateUser}: Props) { /> - - {user.type === "student" && ( - setPassportID(e)} - placeholder="Enter National ID or Passport number" - value={passport_id} - required - /> - )} {user.type === "agent" && } - + + {user.type === "student" ? ( + + setPassportID(e)} + placeholder="Enter National ID or Passport number" + value={passport_id} + required + /> + + + ) : ( - + )}