Skip to content

Commit

Permalink
fix: DeprecationWarning: invalid escape sequence '\+'
Browse files Browse the repository at this point in the history
fix this issue arising when running a test suite AfricasTalkingLtd#54 (comment)
  • Loading branch information
godwins3 authored Jun 29, 2024
1 parent 12acb56 commit de7fa61
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion africastalking/Service.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def validate_amount(amount_str):

def validate_phone(phone_str):
try:
return re.match("^\+\d{1,3}\d{3,}$", phone_str)
return re.match(r"^\+\d{1,3}\d{3,}$", phone_str) is not None
except ValueError:
return False

Expand Down

0 comments on commit de7fa61

Please sign in to comment.