Skip to content

onSuccess does not catching errors #136

@alex-stardev

Description

@alex-stardev

Actual result

If during onSuccess callback there will be an error, oneschema is not catching it, so the onRequestClose is called and we cannot retry

onSuccess={async (data) => {
          try {
            await handleData(data);
          } catch (err) {
            console.error(err);
            throw err;
          }
        }}

Expected result

If during onSuccess - there will be an error, it should be passed to onError and user can retry

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