allow cross_origin for /api/alias/new
This commit is contained in:
parent
786d640511
commit
fd7f819803
|
@ -2,6 +2,7 @@ import random
|
||||||
|
|
||||||
import arrow
|
import arrow
|
||||||
from flask import jsonify, request
|
from flask import jsonify, request
|
||||||
|
from flask_cors import cross_origin
|
||||||
|
|
||||||
from app.api.base import api_bp
|
from app.api.base import api_bp
|
||||||
from app.config import EMAIL_DOMAIN
|
from app.config import EMAIL_DOMAIN
|
||||||
|
@ -12,6 +13,7 @@ from app.utils import random_string
|
||||||
|
|
||||||
|
|
||||||
@api_bp.route("/alias/new", methods=["GET", "POST"])
|
@api_bp.route("/alias/new", methods=["GET", "POST"])
|
||||||
|
@cross_origin()
|
||||||
def index():
|
def index():
|
||||||
"""
|
"""
|
||||||
the incoming request must provide a valid api-key in "Authentication" header and
|
the incoming request must provide a valid api-key in "Authentication" header and
|
||||||
|
|
Loading…
Reference in a new issue