Skip to content

bug: prefetchQuery does not throw error when throwOnError is true #309

@kamranayub

Description

@kamranayub

According to the documentation, when prefetchQuery is called with the config option throwOnError set to true, the query should throw when encountering an error. Instead, the error is still swallowed (and since onSuccess / onError callbacks are not invoked with prefetchQuery, the error can not be seen).

I have a test case to reproduce this and will open a PR to propose a fix. It looks like throw error was commented out recently, possibly due to another issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions