Skip to content

Commit

Permalink
Remove shifted callbacks.
Browse files Browse the repository at this point in the history
Closes #112.

File                             Raw         Min         Zip     Min/Zip
index.js                 11045/10.79  3521/03.44  3150/03.08  1336/01.30
  • Loading branch information
flatheadmill committed Jun 28, 2013
1 parent 78112a7 commit 3209929
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 17 deletions.
5 changes: 1 addition & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,6 @@ function cadence () {
if (Error === vargs[0]) {
invocations[0].catchable = callback.catchable = !! vargs.shift();
}
if (Array.prototype.shift === vargs[0]) {
callback.shifted = !! vargs.shift();
}
callback.cadence = vargs;
invocations[0].callbacks.push(callback);
if (vargs.length) {
Expand Down Expand Up @@ -149,7 +146,7 @@ function cadence () {
if (-1 < index) invocation.count++;
return function () {
var vargs = __slice.call(arguments, 0), error;
if (!callback.shifted) error = vargs.shift();
error = vargs.shift();
if (error) {
thrown(invocation, error, callback);
} else {
Expand Down
13 changes: 0 additions & 13 deletions t/cadence/shifted.t.js

This file was deleted.

0 comments on commit 3209929

Please sign in to comment.