Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

data-footstone

Package Overview
Dependencies
Maintainers
1
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

data-footstone - npm Package Compare versions

Comparing version 0.1.6 to 0.1.7

37

dist_cjs/store.js

@@ -151,13 +151,6 @@ 'use strict';

if (this.chain.tail.value.count > newCount) {
this.chain.append(newCount);
this.chain.append(newNode);
}
else {
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= newCount) {
break;
}
cur = cur.next;
}
this.chain.insert(newNode, cur.position);
this._insert(newNode);
}

@@ -171,2 +164,12 @@ }

}
_insert(node) {
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= node.count) {
break;
}
cur = cur.next;
}
this.chain.insert(node, cur.position);
}
put(k, v) {

@@ -179,10 +182,3 @@ let node = this._get(k);

node.value.value = v;
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= node.value.count) {
break;
}
cur = cur.next;
}
this.chain.insert(node, cur.position);
this._insert(node.value);
}

@@ -195,3 +191,8 @@ else {

let newNode = this._createNode(k, v, 1);
this.chain.append(newNode);
if (this.chain.head) {
this._insert(newNode);
}
else {
this.chain.append(newNode);
}
}

@@ -198,0 +199,0 @@ return this.size();

@@ -149,13 +149,6 @@ import { SingleChain, DoublyChain } from './chain.js';

if (this.chain.tail.value.count > newCount) {
this.chain.append(newCount);
this.chain.append(newNode);
}
else {
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= newCount) {
break;
}
cur = cur.next;
}
this.chain.insert(newNode, cur.position);
this._insert(newNode);
}

@@ -169,2 +162,12 @@ }

}
_insert(node) {
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= node.count) {
break;
}
cur = cur.next;
}
this.chain.insert(node, cur.position);
}
put(k, v) {

@@ -177,10 +180,3 @@ let node = this._get(k);

node.value.value = v;
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= node.value.count) {
break;
}
cur = cur.next;
}
this.chain.insert(node, cur.position);
this._insert(node.value);
}

@@ -193,3 +189,8 @@ else {

let newNode = this._createNode(k, v, 1);
this.chain.append(newNode);
if (this.chain.head) {
this._insert(newNode);
}
else {
this.chain.append(newNode);
}
}

@@ -196,0 +197,0 @@ return this.size();

{
"name": "data-footstone",
"version": "0.1.6",
"version": "0.1.7",
"description": "data structure",

@@ -75,3 +75,3 @@ "author": "feigebaobei <18515195415@163.com>",

},
"gitHead": "47e74dbdff2145571f6e3938d9515d800cf07a3d"
"gitHead": "860a90cbc6878943c09e2d31e4d12fa4d0dce078"
}

@@ -189,13 +189,6 @@ // 存储

if (this.chain.tail.value.count > newCount) {
this.chain.append(newCount);
this.chain.append(newNode);
}
else {
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= newCount) {
break;
}
cur = cur.next;
}
this.chain.insert(newNode, cur.position);
this._insert(newNode);
}

@@ -209,2 +202,12 @@ }

}
_insert(node) {
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= node.count) {
break;
}
cur = cur.next;
}
this.chain.insert(node, cur.position);
}
put(k, v) {

@@ -217,10 +220,3 @@ let node = this._get(k);

node.value.value = v;
let cur = this.chain.head;
while (cur) {
if (cur.value.count <= node.value.count) {
break;
}
cur = cur.next;
}
this.chain.insert(node, cur.position);
this._insert(node.value);
}

@@ -233,3 +229,8 @@ else {

let newNode = this._createNode(k, v, 1);
this.chain.append(newNode);
if (this.chain.head) {
this._insert(newNode);
}
else {
this.chain.append(newNode);
}
}

@@ -236,0 +237,0 @@ return this.size();

Sorry, the diff of this file is not supported yet

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