Add support for the featured collection
This commit is contained in:
parent
d26d6ba70e
commit
f23dbcaf05
3 changed files with 20 additions and 1 deletions
9
app.py
9
app.py
|
@ -23,10 +23,10 @@ import timeago
|
|||
from bson.objectid import ObjectId
|
||||
from dateutil import parser
|
||||
from flask import Flask
|
||||
from flask import make_response
|
||||
from flask import Response
|
||||
from flask import abort
|
||||
from flask import jsonify as flask_jsonify
|
||||
from flask import make_response
|
||||
from flask import redirect
|
||||
from flask import render_template
|
||||
from flask import request
|
||||
|
@ -1779,6 +1779,13 @@ def tags(tag):
|
|||
)
|
||||
|
||||
|
||||
@app.route("/featured")
|
||||
def featured():
|
||||
if not is_api_request():
|
||||
abort(404)
|
||||
return jsonify(**activitypub.simple_build_ordered_collection("featured", []))
|
||||
|
||||
|
||||
@app.route("/liked")
|
||||
def liked():
|
||||
if not is_api_request():
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue