Skip to content

Commit

Permalink
Bump 2.4.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Yomguithereal committed Feb 25, 2017
1 parent c14547c commit 8634665
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 11 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## v2.4.2

* Fixing monkey-related memory leak ([@jrust](https://github.com/jrust)).

## v2.4.1

* Fixing `tree/cursor.splice` descriptor ([@Nimelrian](https://github.com/Nimelrian)).
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "baobab",
"main": "build/baobab.min.js",
"version": "2.4.1",
"version": "2.4.2",
"homepage": "https://github.com/Yomguithereal/baobab",
"author": {
"name": "Guillaume Plique",
Expand Down
10 changes: 5 additions & 5 deletions build/baobab.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Baobab
*
* Homepage: https://github.com/Yomguithereal/baobab
* Version: 2.4.1
* Version: 2.4.2
* Author: Yomguithereal (Guillaume Plique)
* License: MIT
*/
Expand Down Expand Up @@ -1146,7 +1146,7 @@ Baobab.helpers = helpers;
/**
* Version
*/
Baobab.VERSION = '2.4.1';
Baobab.VERSION = '2.4.2';
module.exports = exports['default'];

},{"./cursor":3,"./helpers":4,"./monkey":5,"./type":6,"./update":7,"./watcher":8,"emmett":1}],3:[function(require,module,exports){
Expand Down Expand Up @@ -2581,7 +2581,7 @@ function solveUpdate(affectedPaths, comparedPaths) {
*/

function splice(array, startIndex, nb) {
if (nb === undefined) nb = array.length - startIndex;else if (nb === null) nb = 0;else if (Number.isNaN(Number.parseInt(nb))) throw new Error('argument nb ' + nb + ' can not be parsed into a number!');
if (nb === undefined) nb = array.length - startIndex;else if (nb === null) nb = 0;else if (Number.isNaN(Number.parseInt(nb, 10))) throw new Error('argument nb ' + nb + ' can not be parsed into a number!');
nb = Math.max(0, nb);

// Solving startIndex
Expand Down Expand Up @@ -2885,7 +2885,7 @@ var Monkey = (function () {

// Unbinding events
this.tree.off('write', this.writeListener);
this.tree.off('_monkey', this.monkeyListener);
this.tree.off('_monkey', this.recursiveListener);
this.state.killed = true;

// Deleting properties
Expand Down Expand Up @@ -3017,7 +3017,7 @@ type.primitive = function (target) {
*/
type.splicer = function (target) {
if (!type.array(target) || target.length < 1) return false;
if (target.length > 1 && Number.isNaN(Number.parseInt(target[1]))) return false;
if (target.length > 1 && Number.isNaN(Number.parseInt(target[1], 10))) return false;

return anyOf(target[0], ['number', 'function', 'object']);
};
Expand Down
6 changes: 3 additions & 3 deletions build/baobab.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "baobab",
"version": "2.4.1",
"version": "2.4.2",
"description": "JavaScript persistent data tree with cursors.",
"main": "./dist/baobab.js",
"dependencies": {
Expand Down
2 changes: 1 addition & 1 deletion src/baobab.js
Original file line number Diff line number Diff line change
Expand Up @@ -591,4 +591,4 @@ Baobab.helpers = helpers;
/**
* Version
*/
Baobab.VERSION = '2.4.1';
Baobab.VERSION = '2.4.2';

0 comments on commit 8634665

Please sign in to comment.