lazy is only a thing for properties

master
Aevann 2023-10-05 13:12:53 +03:00
parent 019621490a
commit 24e57db432
1 changed files with 0 additions and 2 deletions

View File

@ -1,10 +1,8 @@
from .lazy import lazy
from files.classes.post import Post
from files.classes.comment import Comment
from files.classes.sub import Sub
from flask import request
@lazy
def can_see(user, other):
if isinstance(other, (Post, Comment)):
if not can_see(user, other.author): return False