Skip to content

Commit 274fd84

Browse files
committed
Disabled subscription popup in home screen and normal video
1 parent c04670b commit 274fd84

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/App.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -178,10 +178,10 @@ export function SubscriptionDrawer({
178178
}, [pathname])
179179

180180
useEffect(() => {
181-
const timer = setTimeout(() => {
182-
if (user) setIsOpened(user?.subscription_status?.status !== 'active')
183-
}, 3000)
184-
return () => clearTimeout(timer)
181+
// const timer = setTimeout(() => {
182+
// if (user) setIsOpened(user?.subscription_status?.status !== 'active')
183+
// }, 3000)
184+
// return () => clearTimeout(timer)
185185
}, [])
186186

187187
async function subscriptionAPI() {

src/screens/Video/index.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,9 @@ export default function Video() {
7878
const { video_id } = useParams()
7979
const [videoDetails, setVideoDetails] = useState<VideoDetails | null>(null)
8080
const [isBackBtn, setShowBackButton] = useState(true)
81-
const { setIsOpened } = useSubscriptionDrawer()
81+
// const { setIsOpened } = useSubscriptionDrawer()
8282
const profile: UserProfile = useSelector((state: any) => state.profile)
83-
const isSubscribed = profile?.subscription_status?.status === 'active'
83+
// const isSubscribed = profile?.subscription_status?.status === 'active'
8484

8585
useEffect(() => {
8686
const timer = setTimeout(() => {
@@ -98,7 +98,7 @@ export default function Video() {
9898
}
9999

100100
function clickOnVideo() {
101-
setIsOpened(!isSubscribed)
101+
// setIsOpened(!isSubscribed)
102102
setBackButtonVisibility()
103103
}
104104

@@ -111,7 +111,7 @@ export default function Video() {
111111
useEffect(() => {
112112
setVideoDetails(null)
113113
loadVideoDetails()
114-
setIsOpened(!isSubscribed)
114+
// setIsOpened(!isSubscribed)
115115
}, [video_id])
116116
return (
117117
<>

0 commit comments

Comments
 (0)