diff --git a/helpers.js b/helpers.js index 8a2e1b9..cc2fa45 100644 --- a/helpers.js +++ b/helpers.js @@ -44,4 +44,11 @@ function isValidEmail(email) { function getRandomBoolean() { return Math.random() < 0.5; } - \ No newline at end of file + + /* -------------------------------------------------------------------------- */ +/* check valid phone number */ +/* -------------------------------------------------------------------------- */ +function validateMobileNumber(mobileNumber) { + var pattern = /^\d{10}$/; + return pattern.test(mobileNumber); +} \ No newline at end of file