Skip to content

How can I use the built-in custom errors? #71

@Ptomerty

Description

@Ptomerty

I am rather new to NodeJS, so forgive me for any basic errors.

That said, I've been trying to see if a thrown error is of type AttachmentNotFoundError. However, I don't think this error type is actually exported anywhere, and thus any attempt to use instanceof AttachmentNotFoundError results in TypeError: Right-hand side of 'instanceof' is not an object or ReferenceError: AttachmentNotFoundError is not defined.

Is there any way I can import this from src/types/errors? Thanks!

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