mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-30 01:12:39 +00:00
Show login notification when zap controls clicked while logged out
This commit is contained in:
1 parent
6779d1e345
commit
ca937418be
2 files changed
+2
-7
No files matched your search
@@ -506,10 +506,7 @@ function setChannelZapVisibility(visible) {
|
||||
typeof app?.isUserLoggedIn === "function"
|
||||
? app.isUserLoggedIn()
|
||||
: Boolean(app?.normalizeHexPubkey?.(app?.pubkey));
|
||||
const sessionActorPubkey = getSessionActorPubkey();
|
||||
const hasSessionActor = sessionActorPubkey.length > 0;
|
||||
const sessionOnly = !isLoggedIn && hasSessionActor;
|
||||
const shouldShow = !!visible && (isLoggedIn || sessionOnly);
|
||||
const shouldShow = !!visible;
|
||||
const requiresLogin = shouldShow && !isLoggedIn;
|
||||
|
||||
if (
|
||||
|
||||
@@ -97,9 +97,7 @@ export default class ZapController {
|
||||
setVisibility(visible) {
|
||||
const lightningVisible = !!visible;
|
||||
const loggedIn = this.isUserLoggedIn();
|
||||
const sessionActorAvailable = this.hasSessionActor();
|
||||
const shouldShow =
|
||||
lightningVisible && (loggedIn || sessionActorAvailable);
|
||||
const shouldShow = lightningVisible;
|
||||
const requiresLogin = shouldShow && !loggedIn;
|
||||
const hasWallet = this.hasActiveWalletConnection();
|
||||
if (this.videoModal) {
|
||||
|
||||
Reference in new issue
Block a user