Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: Authorization fallback #1957

Merged
merged 1 commit into from
Feb 15, 2016
Merged

Conversation

dvoytenko
Copy link
Contributor

Closes #1906.

(No tests yet)

This RFC item proposes to add an optional "authorizationFallback" configuration property that will be used in case when the authorization fails.

/cc @jugglingcats, @ashwinlimaye, @sebastianbenz, @andreban

@dvoytenko
Copy link
Contributor Author

@cramforce This is now ready for review. PTAL.

@@ -350,6 +352,16 @@ export class AccessService {
credentials: 'include',
requireAmpResponseSourceOrigin: true
}));
}).catch(error => {
this.analyticsEvent_('access-authorization-failed');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please write a test for this.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I mean the full function

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Working on tests still as specified above. Will be available soon.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@dvoytenko dvoytenko force-pushed the access38 branch 2 times, most recently from 6e527df to a7b0d4a Compare February 15, 2016 19:48
@dvoytenko
Copy link
Contributor Author

@cramforce PTAL.

@cramforce
Copy link
Member

LGTM

dvoytenko added a commit that referenced this pull request Feb 15, 2016
RFC: Authorization fallback
@dvoytenko dvoytenko merged commit 5acdd96 into ampproject:master Feb 15, 2016
@dvoytenko dvoytenko deleted the access38 branch February 15, 2016 22:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants