removed console.log statement, simplified reg ex