projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c9e1220
)
If not string, console.log should just print it without trying to format
author
Ryan Dahl
<ry@tinyclouds.org>
Tue, 29 Jun 2010 04:12:33 +0000
(21:12 -0700)
committer
Ryan Dahl
<ry@tinyclouds.org>
Tue, 29 Jun 2010 04:20:21 +0000
(21:20 -0700)
src/node.js
patch
|
blob
|
history
diff --git
a/src/node.js
b/src/node.js
index
9edc514
..
fbcd41a
100644
(file)
--- a/
src/node.js
+++ b/
src/node.js
@@
-194,6
+194,7
@@
process.openStdin = function () {
function format (f) {
var i = 1;
var args = arguments;
+ if (!(f instanceof String)) return f;
return f.replace(/%([sdf])/g, function (x) {
switch (x) {
case '%s': return args[i++];