js: phone-number: attack of the higher order functions