forked from MarseyWorld/MarseyWorld
remove param i dont use anymroe
parent
03c3948353
commit
6fdeb0b629
|
@ -94,7 +94,7 @@ def notifications_messages(v):
|
|||
|
||||
# Clear notifications (used for unread indicator only) for all user messages.
|
||||
|
||||
if not session.get("GLOBAL") and not request.values.get('nr'):
|
||||
if not session.get("GLOBAL"):
|
||||
notifs_unread_row = g.db.query(Notification.comment_id).join(Comment).filter(
|
||||
Notification.user_id == v.id,
|
||||
Notification.read == False,
|
||||
|
@ -164,7 +164,7 @@ def notifications_modmail(v):
|
|||
if c.author_id == v.id: continue
|
||||
c.unread = c.created_utc > v.last_viewed_modmail_notifs
|
||||
|
||||
if not session.get("GLOBAL") and not request.values.get('nr'):
|
||||
if not session.get("GLOBAL"):
|
||||
v.last_viewed_modmail_notifs = int(time.time())
|
||||
g.db.add(v)
|
||||
|
||||
|
@ -218,7 +218,7 @@ def notifications_posts(v):
|
|||
for p in listing:
|
||||
p.unread = p.created_utc > v.last_viewed_post_notifs
|
||||
|
||||
if not session.get("GLOBAL") and not request.values.get('nr'):
|
||||
if not session.get("GLOBAL"):
|
||||
v.last_viewed_post_notifs = int(time.time())
|
||||
g.db.add(v)
|
||||
|
||||
|
@ -266,7 +266,7 @@ def notifications_modactions(v):
|
|||
for ma in listing:
|
||||
ma.unread = ma.created_utc > v.last_viewed_log_notifs
|
||||
|
||||
if not session.get("GLOBAL") and not request.values.get('nr'):
|
||||
if not session.get("GLOBAL"):
|
||||
v.last_viewed_log_notifs = int(time.time())
|
||||
g.db.add(v)
|
||||
|
||||
|
@ -303,7 +303,7 @@ def notifications_offsite(v):
|
|||
for ma in listing:
|
||||
ma.unread = ma.created_utc > v.last_viewed_offsite_notifs
|
||||
|
||||
if not session.get("GLOBAL") and not request.values.get('nr'):
|
||||
if not session.get("GLOBAL"):
|
||||
v.last_viewed_offsite_notifs = int(time.time())
|
||||
g.db.add(v)
|
||||
|
||||
|
@ -328,7 +328,7 @@ def notifications_offsite(v):
|
|||
def notifications(v):
|
||||
page = get_page()
|
||||
|
||||
if not session.get("GLOBAL") and v.admin_level < PERMS['USER_SHADOWBAN'] and not request.values.get('nr'):
|
||||
if not session.get("GLOBAL") and v.admin_level < PERMS['USER_SHADOWBAN']:
|
||||
unread_and_inaccessible = g.db.query(Notification).join(Notification.comment).join(Comment.author).filter(
|
||||
Notification.user_id == v.id,
|
||||
Notification.read == False,
|
||||
|
@ -407,7 +407,7 @@ def notifications(v):
|
|||
|
||||
if c not in listing: listing.append(c)
|
||||
|
||||
if not n.read and not session.get("GLOBAL") and not request.values.get('nr'):
|
||||
if not n.read and not session.get("GLOBAL"):
|
||||
n.read = True
|
||||
g.db.add(n)
|
||||
|
||||
|
|
Loading…
Reference in New Issue