Skip to content

Escape function before connection #28

@wviveiro

Description

@wviveiro

Hi there!

I am creating a small library to help me building my mysql queries. The goal is to build the query through series of functions and then be able to output the query ready. Once it is ready, I execute query(mystring). However I noticed that I can't run mysql.getClient() before running mysql.connect() and therefore, I can't get the escape function from mysql.getClient().escape

TLDR

Can you please export the function escape from require('mysql')? On this way I don't have to mysql.connect() and mysql.getClient() to use the function.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions