diff -Nru node-extend-shallow-3.0.1/debian/changelog node-extend-shallow-3.0.2/debian/changelog --- node-extend-shallow-3.0.1/debian/changelog 2017-11-25 17:39:45.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/changelog 2019-01-02 21:22:26.000000000 +0000 @@ -1,3 +1,15 @@ +node-extend-shallow (3.0.2-1) unstable; urgency=medium + + * Team upload. + * Update Vcs fields for migration to https://salsa.debian.org/ + * Bump standard version + * Bump debhelper compat + * New upstream version + * Update copyright and dependencies + * Check DEB_BUILD_OPTIONS against nocheck + + -- Paolo Greppi Wed, 02 Jan 2019 22:22:26 +0100 + node-extend-shallow (3.0.1-1) unstable; urgency=medium * Team upload diff -Nru node-extend-shallow-3.0.1/debian/compat node-extend-shallow-3.0.2/debian/compat --- node-extend-shallow-3.0.1/debian/compat 2017-11-25 17:39:45.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/compat 2019-01-02 21:22:26.000000000 +0000 @@ -1 +1 @@ -10 +11 diff -Nru node-extend-shallow-3.0.1/debian/control node-extend-shallow-3.0.2/debian/control --- node-extend-shallow-3.0.1/debian/control 2017-11-25 17:39:45.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/control 2019-01-02 21:22:26.000000000 +0000 @@ -3,15 +3,23 @@ Priority: optional Maintainer: Debian Javascript Maintainers Uploaders: Pirate Praveen -Build-Depends: debhelper (>= 10), nodejs, mocha, node-is-extendable (>= 0.1.0~), node-minimist -Standards-Version: 4.1.1 +Build-Depends: + debhelper (>= 11) + , mocha + , nodejs + , node-is-extendable (>= 1.0.1) + , node-minimist +Standards-Version: 4.3.0 Homepage: https://github.com/jonschlinkert/extend-shallow -Vcs-Git: https://anonscm.debian.org/git/pkg-javascript/node-extend-shallow.git -Vcs-Browser: https://anonscm.debian.org/cgit/pkg-javascript/node-extend-shallow.git +Vcs-Git: https://salsa.debian.org/js-team/node-extend-shallow.git +Vcs-Browser: https://salsa.debian.org/js-team/node-extend-shallow Package: node-extend-shallow Architecture: all -Depends: ${misc:Depends}, nodejs, node-is-extendable (>= 0.1.0~) +Depends: + ${misc:Depends} + , nodejs + , node-is-extendable (>= 1.0.1) Description: extend an object with the properties of additional objects node.js/javascript util. . diff -Nru node-extend-shallow-3.0.1/debian/copyright node-extend-shallow-3.0.2/debian/copyright --- node-extend-shallow-3.0.1/debian/copyright 2017-11-25 17:39:45.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/copyright 2019-01-02 21:22:26.000000000 +0000 @@ -4,11 +4,13 @@ Source: https://github.com/jonschlinkert/extend-shallow Files: * -Copyright: 2016 Jon Schlinkert (https://github.com/jonschlinkert) +Copyright: 2015-2017, Jon Schlinkert (https://github.com/jonschlinkert) License: Expat Files: debian/* -Copyright: 2016 Pirate Praveen +Copyright: + 2016, Pirate Praveen + 2018, Paolo Greppi License: Expat License: Expat @@ -31,4 +33,3 @@ ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - diff -Nru node-extend-shallow-3.0.1/debian/patches/00-assign-symbols.diff node-extend-shallow-3.0.2/debian/patches/00-assign-symbols.diff --- node-extend-shallow-3.0.1/debian/patches/00-assign-symbols.diff 1970-01-01 00:00:00.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/patches/00-assign-symbols.diff 2019-01-02 21:22:26.000000000 +0000 @@ -0,0 +1,26 @@ +Description: Patch away dependency on assign-symbols using the Symbols part of + the ES6 Object.assign method. +Forwarded: not-needed +Author: Paolo Greppi + +Index: node-extend-shallow/index.js +=================================================================== +--- node-extend-shallow.orig/index.js ++++ node-extend-shallow/index.js +@@ -1,7 +1,6 @@ + 'use strict'; + + var isExtendable = require('is-extendable'); +-var assignSymbols = require('assign-symbols'); + + module.exports = Object.assign || function(obj/*, objects*/) { + if (obj === null || typeof obj === 'undefined') { +@@ -17,7 +16,7 @@ module.exports = Object.assign || functi + } + if (isObject(val)) { + assign(obj, val); +- assignSymbols(obj, val); ++ Object.assign(obj, val); + } + } + return obj; diff -Nru node-extend-shallow-3.0.1/debian/patches/series node-extend-shallow-3.0.2/debian/patches/series --- node-extend-shallow-3.0.1/debian/patches/series 1970-01-01 00:00:00.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/patches/series 2019-01-02 21:22:26.000000000 +0000 @@ -0,0 +1 @@ +00-assign-symbols.diff diff -Nru node-extend-shallow-3.0.1/debian/rules node-extend-shallow-3.0.2/debian/rules --- node-extend-shallow-3.0.1/debian/rules 2017-11-25 17:39:45.000000000 +0000 +++ node-extend-shallow-3.0.2/debian/rules 2019-01-02 21:22:26.000000000 +0000 @@ -4,4 +4,6 @@ dh $@ override_dh_auto_test: +ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) mocha -R spec +endif diff -Nru node-extend-shallow-3.0.1/index.js node-extend-shallow-3.0.2/index.js --- node-extend-shallow-3.0.1/index.js 2017-11-21 05:16:12.000000000 +0000 +++ node-extend-shallow-3.0.2/index.js 2018-04-23 12:45:35.000000000 +0000 @@ -1,15 +1,23 @@ 'use strict'; var isExtendable = require('is-extendable'); +var assignSymbols = require('assign-symbols'); module.exports = Object.assign || function(obj/*, objects*/) { if (obj === null || typeof obj === 'undefined') { - throw new TypeError('expected an object'); + throw new TypeError('Cannot convert undefined or null to object'); + } + if (!isObject(obj)) { + obj = {}; } for (var i = 1; i < arguments.length; i++) { var val = arguments[i]; + if (isString(val)) { + val = toObject(val); + } if (isObject(val)) { assign(obj, val); + assignSymbols(obj, val); } } return obj; @@ -23,6 +31,18 @@ } } +function isString(val) { + return (val && typeof val === 'string'); +} + +function toObject(str) { + var obj = {}; + for (var i in str) { + obj[i] = str[i]; + } + return obj; +} + function isObject(val) { return (val && typeof val === 'object') || isExtendable(val); } @@ -34,3 +54,7 @@ function hasOwn(obj, key) { return Object.prototype.hasOwnProperty.call(obj, key); } + +function isEnum(obj, key) { + return Object.prototype.propertyIsEnumerable.call(obj, key); +} diff -Nru node-extend-shallow-3.0.1/package.json node-extend-shallow-3.0.2/package.json --- node-extend-shallow-3.0.1/package.json 2017-11-21 05:16:12.000000000 +0000 +++ node-extend-shallow-3.0.2/package.json 2018-04-23 12:45:35.000000000 +0000 @@ -1,7 +1,7 @@ { "name": "extend-shallow", "description": "Extend an object with the properties of additional objects. node.js/javascript util.", - "version": "3.0.1", + "version": "3.0.2", "homepage": "https://github.com/jonschlinkert/extend-shallow", "author": "Jon Schlinkert (https://github.com/jonschlinkert)", "contributors": [ @@ -24,6 +24,7 @@ "test": "mocha" }, "dependencies": { + "assign-symbols": "^1.0.0", "is-extendable": "^1.0.1" }, "devDependencies": { diff -Nru node-extend-shallow-3.0.1/test.js node-extend-shallow-3.0.2/test.js --- node-extend-shallow-3.0.1/test.js 2017-11-21 05:16:12.000000000 +0000 +++ node-extend-shallow-3.0.2/test.js 2018-04-23 12:45:35.000000000 +0000 @@ -8,11 +8,11 @@ 'use strict'; require('mocha'); -const hasSymbol = typeof global.Symbol === 'function'; -const path = require('path'); -const argv = require('minimist')(process.argv.slice(2)); -const assert = require('assert'); -const extend = require('./'); +var hasSymbol = typeof global.Symbol === 'function'; +var path = require('path'); +var argv = require('minimist')(process.argv.slice(2)); +var assert = require('assert'); +var extend = require('./'); if (argv && argv.lib) { extend = require(path.resolve('benchmark/code', argv.lib)); @@ -31,21 +31,21 @@ }); it('should extend a regex', function() { - const fixture = /foo/; + var fixture = /foo/; extend(fixture, {a: 'b'}, new Date(), {c: 'd'}); assert.equal(fixture.a, 'b'); assert.equal(fixture.c, 'd'); }); it('should extend a function', function() { - const fixture = function() {}; + var fixture = function() {}; extend(fixture, {a: 'b'}, new Date(), {c: 'd'}); assert.equal(fixture.a, 'b'); assert.equal(fixture.c, 'd'); }); it('should extend an array', function() { - const arr = []; + var arr = []; extend(arr, {a: 'b'}, new Date(), {c: 'd'}); assert.equal(arr.a, 'b'); assert.equal(arr.c, 'd'); @@ -69,24 +69,24 @@ it('should not extend non-enumerable symbols', function() { if (!hasSymbol) return this.skip(); - const fixture = {}; - const obj = {}; - const symbol = Symbol('foo'); + var fixture = {}; + var obj = {}; + var symbol = Symbol('foo'); Object.defineProperty(obj, symbol, {enumerable: false, value: 'bar'}); extend(fixture, obj); - const other = extend({}, obj); + var other = extend({}, obj); assert.equal(typeof fixture[symbol], 'undefined'); assert.equal(typeof other[symbol], 'undefined'); }); it('should extend symbol properties', function() { if (!hasSymbol) return this.skip(); - const fixture = {}; - const obj = {}; - const symbol = Symbol('foo'); + var fixture = {}; + var obj = {}; + var symbol = Symbol('foo'); obj[symbol] = 'bar'; extend(fixture, obj); - const other = extend({}, obj); + var other = extend({}, obj); assert.equal(fixture[symbol], 'bar'); assert.equal(other[symbol], 'bar'); });