lib/commands/frame.js
function (selector, hash) {
    if (selector !== null) {
      this.actionQueue.push(this.webdriverClient.element.bind(this.webdriverClient, selector));
    }
    this.actionQueue.push(this.webdriverClient.frame.bind(this.webdriverClient));
    this.actionQueue.push(this._frameCb.bind(this, selector, hash));
    return this;
  }
function (selector, hash) {
    if (selector !== null) {
      this.actionQueue.push(this.webdriverClient.element.bind(this.webdriverClient, selector));
    }
    this.actionQueue.push(this.webdriverClient.frame.bind(this.webdriverClient));
    this.actionQueue.push(this._frameCb.bind(this, selector, hash));
    return this;
  }
function ( selector , hash ) { if ( selector !== null ) { this . actionQueue . push ( this . webdriverClient . element . bind ( this . webdriverClient , selector ) ) ; } this . actionQueue . push ( this . webdriverClient . frame . bind ( this . webdriverClient ) ) ; this . actionQueue . push ( this . _frameCb . bind ( this , selector , hash ) ) ; return this ; }
Switches to frame context

@method toFrame
@param {string} selector Selector expression to find the element
@param {string} hash Unique hash of that fn call
@chainable
Switches to frame context