AntonNiklasson / eslint-plugin-knex

Lint rule(s) for Knex.js
9 stars 8 forks source link

fix: exit early if query variable is a parameter #18

Open Sekhmet opened 2 years ago

Sekhmet commented 2 years ago

For parameters we shouldn't check for .init as it won't be defined. Currently using knex.raw inside of function or arrow function will crash eslint if query came from parameter.

This PR fixes this issue.