Socket
Socket
Sign inDemoInstall

hashmap

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hashmap - npm Package Compare versions

Comparing version 2.0.5 to 2.0.6

.jshintrc

2

bower.json
{
"name": "hashmap",
"version": "2.0.5",
"version": "2.0.6",
"description": "HashMap Class for JavaScript",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/flesler/hashmap",

# Changelog
## 2.0.6
- Names of chained methods is hardcoded rather than using the "return" trick. Fixes bug when minified, thanks @fresheneesz.
- Added jshint to be run before any commit
## 2.0.5

@@ -10,3 +14,3 @@ - count() is now O(1), thanks @qbolec

## 2.0.3
- forEach method accepts a context as 2nd argument (thanks mvayngrib)
- forEach method accepts a context as 2nd argument, thanks @mvayngrib

@@ -27,6 +31,6 @@ ## 2.0.2

## 1.2.0
- Added search() method, (thanks rafalwrzeszcz)
- Added search() method, thanks @rafalwrzeszcz
## 1.1.0
- AMD support, (thanks khrome)
- AMD support, thanks @khrome

@@ -33,0 +37,0 @@ ## 1.0.1

/**
* HashMap - HashMap Class for JavaScript
* @author Ariel Flesler <aflesler@gmail.com>
* @version 2.0.5
* @version 2.0.6
* Homepage: https://github.com/flesler/hashmap

@@ -9,2 +9,3 @@ */

(function(factory) {
/* global define */
if (typeof define === 'function' && define.amd) {

@@ -164,14 +165,11 @@ // AMD. Register as an anonymous module.

//- Automatically add chaining to some methods
//- Add chaining to all methods that don't return something
for (var method in proto) {
// Skip constructor, valueOf, toString and any other built-in method
if (method === 'constructor' || !proto.hasOwnProperty(method)) {
continue;
}
['set','multi','copy','remove','clear','forEach'].forEach(function(method) {
var fn = proto[method];
if (fn.toString().indexOf('return ') === -1) {
proto[method] = chain(fn);
}
}
proto[method] = function() {
fn.apply(this, arguments);
return this;
};
});

@@ -186,9 +184,2 @@ //- Utils

function chain(fn) {
return function() {
fn.apply(this, arguments);
return this;
};
}
function hide(obj, prop) {

@@ -195,0 +186,0 @@ // Make non iterable if supported

{
"name": "hashmap",
"author": "Ariel Flesler <aflesler@gmail.com>",
"version": "2.0.5",
"version": "2.0.6",
"description": "HashMap Class for JavaScript",

@@ -23,4 +23,4 @@ "keywords": [

"scripts": {
"test": "mocha test/*.js",
"prepush": "npm test -- --reporter dot"
"precommit": "jshint hashmap.js",
"prepush": "mocha test/ --reporter dot"
},

@@ -32,6 +32,7 @@ "engines": {

"devDependencies": {
"chai": "^3.5.0",
"husky": "^0.11.4",
"mocha": "^2.4.5"
"chai": "3.5.0",
"husky": "0.11.4",
"jshint": "2.9.2",
"mocha": "2.5.1"
}
}

@@ -126,3 +126,3 @@ # HashMap Class for JavaScript

Copyright (c) 2012-2015 Ariel Flesler
Copyright (c) 2012 Ariel Flesler

@@ -129,0 +129,0 @@ Permission is hereby granted, free of charge, to any person obtaining a copy

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc