Skip to content
This repository has been archived by the owner on Sep 22, 2022. It is now read-only.

Commit

Permalink
fix error when phone number starts with 91
Browse files Browse the repository at this point in the history
91 is india code however india also has mobile number series of 91 available for public consumption.
  • Loading branch information
anantshri authored May 3, 2022
1 parent ea92719 commit 5978d13
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions upi-recon.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def address_discovery(vpa, api_url):
# set variables and normalize input
API_URL = 'https://api.razorpay.com/v1/payments/validate/account?key_id='
api_key_id = config.get('main', 'api_key_id')
phone = arguments.phone[2:] if arguments.phone[0:2] == '91' else arguments.phone
phone = arguments.phone[2:] if arguments.phone[0:2] == '91' and len(arguments.phone) > 10 else arguments.phone
# check if api_key_id is correct
if api_key_id and not api_key_id[0:3] == 'rzp':
quit('[!] invalid api_key_id')
Expand Down Expand Up @@ -112,4 +112,4 @@ def address_discovery(vpa, api_url):
print('\n[!] interrupted! stopping threads...')
exit(1)
print('[i] finished at ' + datetime.now().strftime("%d/%m/%Y %H:%M:%S"))
exit(1)
exit(1)

0 comments on commit 5978d13

Please sign in to comment.