prompt-question
Advanced tools
Comparing version 3.0.2 to 3.0.3
10
index.js
@@ -74,3 +74,11 @@ 'use strict'; | ||
Question.prototype.clone = function() { | ||
return new this.constructor(clone(this.cache)); | ||
var keys = Object.keys(this); | ||
var cloned = new this.constructor(clone(this.cache)); | ||
for (var i = 0; i < keys.length; i++) { | ||
var key = keys[i]; | ||
if (!(key in cloned)) { | ||
cloned[key] = this[key]; | ||
} | ||
} | ||
return cloned; | ||
}; | ||
@@ -77,0 +85,0 @@ |
{ | ||
"name": "prompt-question", | ||
"description": "Question object, used by Enquirer and prompt plugins.", | ||
"version": "3.0.2", | ||
"version": "3.0.3", | ||
"homepage": "https://github.com/enquirer/prompt-question", | ||
@@ -30,3 +30,3 @@ "author": "Jon Schlinkert (https://github.com/jonschlinkert)", | ||
"koalas": "^1.0.2", | ||
"prompt-choices": "^3.0.1" | ||
"prompt-choices": "^3.0.3" | ||
}, | ||
@@ -33,0 +33,0 @@ "devDependencies": { |
14649
294
Updatedprompt-choices@^3.0.3