Skip to content

typeof will never evaluate to 'JoinClause' #73

@talltyler

Description

@talltyler

There is an error on this line

if (typeof statement === 'JoinClause' || statement?.grouping === 'join') {

From my understanding if this _statement is a string here but still looking closer so not 100%.
But typeof will evaluate to 'string' not 'JoinClause' if so and if it is an object which the next thing is assuming then type of will return 'object'.
Maybe you are looking for instanceOf? Either way there is something not right with this line.

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