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

Consistently use Error::NotAvailable instead of Unsupported #349

Merged
merged 2 commits into from
Mar 13, 2024

Commits on Mar 12, 2024

  1. Configuration menu
    Copy the full SHA
    8dca57d View commit details
    Browse the repository at this point in the history
  2. switch most uses of Error::Unsupported to Error::NotAvailable

    `Unsupported` is meant to express things that are not supported by the
    platform, for example trying to make a request with "HTTP/4".
    
    `NotAvailable` is meant to express things that are not available or
    unimplemented in Viceroy.
    
    Previously, `Unsupported` would return `FastlyStatus::Unsupported` and
    `NotAvailable` would return the generic `FastlyStatus::Error`.  This
    led to a bad user experience for the `NotAvailable` case, as the user
    would see an opaque and generic "Error" message rather than
    "Unsupported".  The previous commit fixes this by having both
    `Unsupported` and `NotAvailable` return `FastlyStatus::Unsupported`.
    
    This commit makes our use of `NotAvailable` consistent.
    joeshaw committed Mar 12, 2024
    Configuration menu
    Copy the full SHA
    491b54c View commit details
    Browse the repository at this point in the history