Skip to content

Get without callback returns incorrect signature #141

Description

@simonbrent

The documentation for Client.prototype.get states:

// The callback signature is:
//
// callback(err, value, flags)

but the code contains the following:

  if(callback === undefined) {
    return promisify(function(callback) {
      self.get(key, function(err, value, flags) {
        callback(err, {value: value, flags: flags});
      });
    });
  }

Changing this to

  if(callback === undefined) {
    return promisify(function(callback) {
      self.get(key, callback)
    });
  }

would fix this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions