function createChecker(callback, contextObject) {
      if (callback && contextObject) {

        // compare by matching with both callback and context
        return function (subscriber, fn, context) {
          return subscriber.callback === fn && subscriber.context === context;
        };
      }
      if (typeof callback === 'function') {

        // compare only by callback
        return function (subscriber, fn) {
          return subscriber.callback === fn;
        };
      }
      // if only one parameter passed
      if (isObject(callback)) {

        // compare only by context
        return function (subscriber, context) {
          return subscriber.context === context;
        };
      }
      return function () {
      };
    }
// Returns function which logic depends on passed arguments values.
Returns function which logic depends on passed arguments values.
Returns function which logic depends on passed arguments values .
function createChecker(callback, contextObject) {
      if (callback && contextObject) {
        return function (subscriber, fn, context) {
          return subscriber.callback === fn && subscriber.context === context;
        };
      }
      if (typeof callback === 'function') {
        return function (subscriber, fn) {
          return subscriber.callback === fn;
        };
      }
      if (isObject(callback)) {
        return function (subscriber, context) {
          return subscriber.context === context;
        };
      }
      return function () {
      };
    }
function createChecker ( callback , contextObject ) { if ( callback && contextObject ) { return function ( subscriber , fn , context ) { return subscriber . callback === fn && subscriber . context === context ; } ; } if ( typeof callback === 'function' ) { return function ( subscriber , fn ) { return subscriber . callback === fn ; } ; } if ( isObject ( callback ) ) { return function ( subscriber , context ) { return subscriber . context === context ; } ; } return function ( ) { } ; }
Returns function which logic depends on passed arguments values.
Returns function which logic depends on passed arguments values .
// compare by matching with both callback and context // compare only by callback // if only one parameter passed // compare only by context