Skip to content

TypeError thrown if dispatched method resolves with a string #45

@janeysaur

Description

@janeysaur

Ran into an issue with this line: https://github.com/respond-framework/rudy/blob/master/packages/rudy/src/core/createRequest.js#L166

      ...
    return Promise.resolve(dispatch(action)) // dispatch transformed action
      .then((res) => {
        ...
=>      if (res) res._dispatched = true // tell `middleware/call/index.js` to NOT automatically dispatch callback returns

        return res
      })
  }```

when my dispatched method resolved with a string return value. 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions