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

Refactor: Create libs/ApiUtils #15178

Merged
merged 23 commits into from
Mar 16, 2023
Merged

Commits on Mar 9, 2023

  1. CONFIG - rename API ROOT urls for clarity

    This makes it clear that we don't have a `URL_API_ROOT` that works both on staging and prod
    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    743ae89 View commit details
    Browse the repository at this point in the history
  2. Create libs/ApiUtils

    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    db491dd View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a851403 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    4c60df7 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    92bb599 View commit details
    Browse the repository at this point in the history
  6. Update TestToolMenu to use ApiUtils

    Default the initial toggle value to `ApiUtils.isUsingStagingApi()`
    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    8cf601b View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    9c64b57 View commit details
    Browse the repository at this point in the history
  8. Rename CONFIG.PRODUCTION_API_ROOT to PRIMARY_API_ROOT

    Changed the name to PRIMARY to better represent the value
    - It's the primary and preferred API root on DEV and PROD
    - We can toggle between PRIMARY and STAGING on DEV or STAGING
    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    6df8c6f View commit details
    Browse the repository at this point in the history
  9. Apply suggestions from code review

    Co-authored-by: Marc Glasser <marc.aaron.glasser@gmail.com>
    kidroca and marcaaron committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    4708122 View commit details
    Browse the repository at this point in the history
  10. Document PRIMARY_API_ROOT

    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    595bb23 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    6d88ebf View commit details
    Browse the repository at this point in the history
  12. ApiUtils: Add missing docks

    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    8f85692 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    b75f313 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    ebdb915 View commit details
    Browse the repository at this point in the history
  15. Rename CONFIG.PRIMARY_API_ROOT to DEFAULT

    Changed the name to DEFAULT to better represent the value
    - It's the default and preferred API root on DEV and PROD
    - We can toggle between DEFAULT and STAGING on DEV or STAGING
    kidroca committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    0269102 View commit details
    Browse the repository at this point in the history
  16. ApiUtils - Apply suggestions from code review

    Co-authored-by: Vit Horacek <36083550+mountiny@users.noreply.github.com>
    kidroca and mountiny committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    ca66fba View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    39fd3c6 View commit details
    Browse the repository at this point in the history

Commits on Mar 10, 2023

  1. Configuration menu
    Copy the full SHA
    7b49753 View commit details
    Browse the repository at this point in the history
  2. ApiUtils - Move Onyx.connect inside getEnvironment promise

    Onyx callback should always run after we have ENV_NAME from `getEnvironment`
    kidroca committed Mar 10, 2023
    Configuration menu
    Copy the full SHA
    9be14bc View commit details
    Browse the repository at this point in the history
  3. Update NetworkConnection - use the updated CONFIG value - DEFAULT_API…

    …_ROOT
    
    This was a leftover usage of the old config name that I forgot to update
    Also updated a comment using the old name - URL_API_ROOT
    kidroca committed Mar 10, 2023
    Configuration menu
    Copy the full SHA
    e3d84f9 View commit details
    Browse the repository at this point in the history

Commits on Mar 13, 2023

  1. ApiUtils - remove canUseStagingServer

    Move the logic inside the Onyx callback
    kidroca committed Mar 13, 2023
    Configuration menu
    Copy the full SHA
    3be8792 View commit details
    Browse the repository at this point in the history
  2. Docs: Update src/libs/ApiUtils.js

    Co-authored-by: Abdelhafidh Belalia <16493223+s77rt@users.noreply.github.com>
    kidroca and s77rt authored Mar 13, 2023
    Configuration menu
    Copy the full SHA
    c197b41 View commit details
    Browse the repository at this point in the history

Commits on Mar 16, 2023

  1. Configuration menu
    Copy the full SHA
    d641fa8 View commit details
    Browse the repository at this point in the history