code: function fn(name, options) {
          debug('.findGenerator', name);
          if (utils.isObject(name)) {
            return name;
          }
  
          if (Array.isArray(name)) {
            name = name.join('.');
          }
  
          if (typeof name !== 'string') {
            throw new TypeError('expected name to be a string');
          }
  
          if (cache.hasOwnProperty(name)) {
            return cache[name];
          }
  
          var app = this.generators[name]
            || this.base.generators[name]
            || this._findGenerator(name, options);
  
          // if no app, check the `base` instance
          if (typeof app === 'undefined' && this.hasOwnProperty('parent')) {
            app = this.base._findGenerator(name, options);
          }
  
          if (app) {
            cache[app.name] = app;
            cache[app.alias] = app;
            cache[name] = app;
            return app;
          }
  
          var search = {name, options};
          this.base.emit('unresolved', search, this);
          if (search.app) {
            cache[search.app.name] = search.app;
            cache[search.app.alias] = search.app;
            return search.app;
          }
  
          cache[name] = null;
        }
docs: Find generator `name`, by first searching the cache, then searching the
  cache of the `base` generator. Use this to get a generator without invoking it.
  
  ```js
  // search by "alias"
  var foo = app.findGenerator('foo');
  
  // search by "full name"
  var foo = app.findGenerator('generate-foo');
  ```
  @name .findGenerator
  @param {String} `name`
  @param {Function} `options` Optionally supply a rename function on `options.toAlias`
  @return {Object|undefined} Returns the generator instance if found, or undefined.
  @api public