forked from forks/microblog.pub
Fix admin thread
This commit is contained in:
parent
333e3b314d
commit
5d74f60ab9
1 changed files with 2 additions and 6 deletions
8
app.py
8
app.py
|
@ -1339,13 +1339,9 @@ def admin_lookup():
|
||||||
@login_required
|
@login_required
|
||||||
def admin_thread():
|
def admin_thread():
|
||||||
data = DB.activities.find_one(
|
data = DB.activities.find_one(
|
||||||
{
|
{"type": ActivityType.CREATE.value, "activity.object.id": request.args.get("oid")}
|
||||||
"$or": [
|
|
||||||
{"remote_id": request.args.get("oid")},
|
|
||||||
{"activity.object.id": request.args.get("oid")},
|
|
||||||
]
|
|
||||||
}
|
|
||||||
)
|
)
|
||||||
|
|
||||||
if not data:
|
if not data:
|
||||||
abort(404)
|
abort(404)
|
||||||
if data["meta"].get("deleted", False):
|
if data["meta"].get("deleted", False):
|
||||||
|
|
Loading…
Reference in a new issue