using slice from the array prototype without instantiating a new array on every invocation

This commit is contained in:
zaphod1984 2014-05-22 22:14:30 +02:00
parent 90e2260f58
commit 08cfbade29

View file

@ -29,7 +29,7 @@ function init() {
ret[name] = {
get: function () {
var obj = defineProps(function self() {
var str = [].slice.call(arguments).join(' ');
var str = Array.prototype.slice.call(arguments).join(' ');
if (!chalk.enabled) {
return str;