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

Sync Tenant Flags with API v2 #467

Merged
merged 5 commits into from
Feb 1, 2021
Merged

Conversation

frederikprijck
Copy link
Member

The PR syncs the TenantFlags class with the available flags on the API v2 based on https://auth0.com/docs/api/management/v2#!/Tenants/get_settings

Closes #465

@frederikprijck frederikprijck changed the title Sync Tenant Flags with API v2 [WIP] Sync Tenant Flags with API v2 Feb 1, 2021
settingsUpdateResponse.Flags.DisableClickjackProtectionHeaders.Should().BeTrue();
settingsUpdateResponse.Flags.EnableAPIsSection.Should().BeTrue();
settingsUpdateResponse.Flags.EnableClientConnections.Should().BeFalse();
settingsUpdateResponse.Flags.EnablePipeline2.Should().BeTrue();
Copy link
Member Author

@frederikprijck frederikprijck Feb 1, 2021

Choose a reason for hiding this comment

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

Previously we could do a full object comparison, because a lot of properties where not included.
Now, this is not the case anymore as it might be that the values of certain flags are already set to true/false in the Database, while they are not part of the update call here. So the flags we are sent are not identical to the flags we are retrieving.

Example:

Database:

  • Flag 1: true
  • Flag 2: false

Update call:

  • Set Flag 2 to true
  • Pass Flag 1 as NULL to not update it

Response:

  • Flag 1: true
  • Flag 2: true

@frederikprijck frederikprijck marked this pull request as ready for review February 1, 2021 09:36
@frederikprijck frederikprijck requested a review from a team as a code owner February 1, 2021 09:36
@frederikprijck frederikprijck changed the title [WIP] Sync Tenant Flags with API v2 Sync Tenant Flags with API v2 Feb 1, 2021
@frederikprijck frederikprijck merged commit 297affb into master Feb 1, 2021
@frederikprijck frederikprijck deleted the frederik/feat/tenant-flahs branch February 1, 2021 22:16
@frederikprijck frederikprijck added this to the vNext milestone Feb 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TenantFlags are not inclusive of all tenant flags
2 participants