beautify 1st part of the tutorial

This commit is contained in:
Ilya Kantor 2015-03-10 12:36:58 +03:00
parent e3dd2cedc0
commit 6444024a9d
327 changed files with 2358 additions and 1986 deletions

View file

@ -16,7 +16,7 @@ var newStr = str[0].toUpperCase() + str.slice(1);
//+ run
function ucFirst(str) {
// только пустая строка в логическом контексте даст false
if (!str) return str;
if (!str) return str;
return str[0].toUpperCase() + str.slice(1);
}