Skip to content

Commit

Permalink
Use strict mode
Browse files Browse the repository at this point in the history
  • Loading branch information
erayd committed Sep 29, 2016
1 parent 0bd4377 commit ae8d599
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "spique",
"version": "1.0.7",
"version": "1.0.8",
"description": "A spiral deque - high performance and dynamic queue size",
"main": "spique.js",
"scripts": {
Expand Down
5 changes: 3 additions & 2 deletions spique.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
* ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/

"use strict";
module.exports = Spique;

function Spique(maxItems, ringSize) {
Expand Down Expand Up @@ -44,7 +45,7 @@ function Spique(maxItems, ringSize) {

// push item(s) onto the end of the buffer
this.enqueue = this.push = function() {
for(value of arguments) {
for(var value of arguments) {
if(items >= maxItems)
return new Error('Buffer is full');
// add another ring if necessary
Expand All @@ -62,7 +63,7 @@ function Spique(maxItems, ringSize) {

// push item(s) onto the start of the buffer
this.unshift = function(value) {
for(value of arguments) {
for(var value of arguments) {
if(items >= maxItems)
return new Error('Buffer is full');
// add another ring if necessary
Expand Down

0 comments on commit ae8d599

Please sign in to comment.