return null if impersonating (#4939)
parent
47e496fded
commit
9453c1fc3a
|
@ -1,3 +1,4 @@
|
|||
import { useSession } from "next-auth/react";
|
||||
import { useState, useEffect } from "react";
|
||||
|
||||
import dayjs from "@calcom/dayjs";
|
||||
|
@ -53,6 +54,10 @@ export default function TimezoneChangeDialog() {
|
|||
toast && showToast(t("we_wont_show_again"), "success");
|
||||
}
|
||||
|
||||
const { data } = useSession();
|
||||
|
||||
if (data?.user.impersonatedByUID) return null;
|
||||
|
||||
return (
|
||||
<Dialog open={open} onOpenChange={setOpen}>
|
||||
<DialogContent
|
||||
|
|
Loading…
Reference in New Issue