build/rekord.js
function(delaySort)
  {
    var removed = AP.shift.apply( this );

    this.trigger( Collection.Events.Remove, [this, removed, 0] );

    if ( !delaySort )
    {
      this.sort( undefined, undefined, true );
    }

    return removed;
  }
function(delaySort)
  {
    var removed = AP.shift.apply( this );

    this.trigger( Collection.Events.Remove, [this, removed, 0] );

    if ( !delaySort )
    {
      this.sort( undefined, undefined, true );
    }

    return removed;
  }
function ( delaySort ) { var removed = AP . shift . apply ( this ) ; this . trigger ( Collection . Events . Remove , [ this , removed , 0 ] ) ; if ( ! delaySort ) { this . sort ( undefined , undefined , true ) ; } return removed ; }
Removes the first element in this collection and returns it - sorting the
collection if a comparator is set on this collection and `delaySort` is
no specified or a true value.

```javascript
var c = Rekord.collect(1, 2, 3, 4);
c.shift(); // 1
```

@method
@memberof Rekord.Collection#
@param {Boolean} [delaySort=false] -
Whether automatic sorting should be delayed until the user manually
calls {@link Rekord.Collection#sort sort}.
@return {Any} -
The element removed from the beginning of the collection.
@emits Rekord.Collection#remove
@emits Rekord.Collection#sort
Removes the first element in this collection and returns it - sorting the collection if a comparator is set on this collection and delaySort is no specified or a true value .