File tree 1 file changed +11
-1
lines changed
readthedocs/restapi/views 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -349,7 +349,7 @@ class IsAuthenticatedOrHasToken(permissions.IsAuthenticated):
349
349
"""
350
350
351
351
def has_permission (self , request , view ):
352
- has_perm = ( super ().has_permission (request , view ) )
352
+ has_perm = super ().has_permission (request , view )
353
353
return has_perm or 'token' in request .data
354
354
355
355
@@ -420,8 +420,18 @@ class WebhookView(APIView):
420
420
ever get webhook requests for established webhooks on our side. The other
421
421
views can receive webhooks for unknown webhooks, as all legacy webhooks will
422
422
be.
423
+
424
+ .. warning::
425
+ We're turning off Authenication for this view.
426
+ This fixes a bug where we were double-authenticating these views,
427
+ because of the way we're passing the request along to the subviews.
428
+
429
+ If at any time we add real logic to this view,
430
+ it will be completely unauthenticated.
423
431
"""
424
432
433
+ authentication_classes = []
434
+
425
435
VIEW_MAP = {
426
436
Integration .GITHUB_WEBHOOK : GitHubWebhookView ,
427
437
Integration .GITLAB_WEBHOOK : GitLabWebhookView ,
You can’t perform that action at this time.
0 commit comments