FamilySearch/fs-js-lite

Unhelpful error when request options are undefined

Opened this issue · 0 comments

When calling a request method and passing undefined for the request options as the second parameter

fs.get(url, options, function(){ });

Then an unhelpful error is thrown from inside the SDK because the SDK assumes that the options object exists and is an object when three parameters are present on the method. It should either default to an empty options object or throw a helpful error.