aboutsummaryrefslogtreecommitdiff
path: root/src/web/views/api/v3/common.py
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2016-04-19 13:25:02 +0200
committerCédric Bonhomme <cedric@cedricbonhomme.org>2016-04-19 13:25:02 +0200
commitd78d0c0136531093ad66a093d6cc0695967fc043 (patch)
treebf1b8efe583186b7177208bfce43abea8f707780 /src/web/views/api/v3/common.py
parentCheck is the user is authenticated before checking if the user is authorized ... (diff)
downloadnewspipe-d78d0c0136531093ad66a093d6cc0695967fc043.tar.gz
newspipe-d78d0c0136531093ad66a093d6cc0695967fc043.tar.bz2
newspipe-d78d0c0136531093ad66a093d6cc0695967fc043.zip
Defined an url prefix for the new API.
Diffstat (limited to 'src/web/views/api/v3/common.py')
-rw-r--r--src/web/views/api/v3/common.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/web/views/api/v3/common.py b/src/web/views/api/v3/common.py
index 8831b8ba..b4e6b62e 100644
--- a/src/web/views/api/v3/common.py
+++ b/src/web/views/api/v3/common.py
@@ -3,6 +3,9 @@ from flask.ext.restless import ProcessingException
from web.controllers import ArticleController
+url_prefix = '/api/v3'
+
+
def is_authorized_to_modify(user, obj):
return user.id == obj.user_id
bgstack15