BB2-3532: Added check for flag for ag_expiration info #1266
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
JIRA Ticket:
BB2-3532
What Does This PR Do?
Adds a check for whether or not the feature flag for data access grants is active. If it is not, then the ag expiration date will always be an empty string.
What Should Reviewers Watch For?
While testing, use your local app and uncheck the "Superusers" box on the waffle flag for "limit_data_access". This option will otherwise pretend that the flag is always on for superuser accounts, complicating testing.
If you're reviewing this PR, please check for these things in particular:
Validation
Create a local app, set the local waffle flag superuser option to false, then get an access token for your app. The expiration date field should be an empty string. If you flip the flag back on for superusers or enable it for your app, you will see a date again.
What Security Implications Does This PR Have?
Please indicate if this PR does any of the following:
security engineer's approval.
Any Migrations?
etc)