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

WithUnknownValue to treat unknown values as a non-error #24

Merged
merged 1 commit into from Nov 3, 2021

Commits on Nov 2, 2021

  1. WithUnknownValue to treat unknown values as a non-error

    This introduces a new option "WithUnknownValue" that can be used to
    specify some value to use for unknown keys. Normally, bexpr will error
    (and this continues to be the default). However, an alternate zero value
    behavior can be specified to use that instead.
    
    This is useful for situations where you want to treat empty values as
    say... empty string so that an expression generally fails but with a
    false rather than an error.
    
    This also updates to pointerstructure 1.2.1 which fixes on "not found"
    case that wasn't wrapping ErrNotFound properly.
    mitchellh committed Nov 2, 2021
    Copy the full SHA
    46883af View commit details
    Browse the repository at this point in the history