Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request.input should not allow 0 arguments #885

Merged
merged 2 commits into from
Jul 1, 2019
Merged

Request.input should not allow 0 arguments #885

merged 2 commits into from
Jul 1, 2019

Commits on Jun 29, 2019

  1. Request.input should not allow 0 arguments

    `Request.input` has a check at [L1150](https://github.com/tediousjs/node-mssql/blob/41f374105f048a5a4fc682b88bc0a431104fae89/lib/base.js#L1150) where it's supposed to ensure that at least two parameters are passed to the function, however it only checks `if (arguments.length === 1) {` and thus calling the function without any arguments passes this test throwing a TypeError at L1170 instead of an EARGS error like expected. [example](https://runkit.com/swant/mssql-request-input-doesn-t-throw-properly)
    swantzter authored Jun 29, 2019
    Configuration menu
    Copy the full SHA
    da6f92b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    b9af31e View commit details
    Browse the repository at this point in the history