summaryrefslogtreecommitdiff
path: root/server/utils/otp.js
blob: 091f6c1db807c8b822afbe9b1260ef0fdcc3b20e (plain)
1
2
3
4
5
6
7
8
9
10
import {ONE_FIVE_TIMES_ZERO, NINE_FIVE_TIMES_ZERO} from '../constants/numbers';

const generateOTP = () => {
  const otp = Math.floor(
    ONE_FIVE_TIMES_ZERO + Math.random() * NINE_FIVE_TIMES_ZERO
  );
  return otp;
};

export default generateOTP;