mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-04 18:31:13 -05:00
restore international numbers
This commit is contained in:
@@ -48,7 +48,9 @@ class AwsSnsClient(SmsClient):
|
||||
|
||||
def send_sms(self, to, content, reference, sender=None, international=False):
|
||||
matched = False
|
||||
for match in phonenumbers.PhoneNumberMatcher(to, "US"):
|
||||
if "+" not in to:
|
||||
to = f"+{to}"
|
||||
for match in phonenumbers.PhoneNumberMatcher(to, None):
|
||||
matched = True
|
||||
to = phonenumbers.format_number(
|
||||
match.number, phonenumbers.PhoneNumberFormat.E164
|
||||
|
||||
@@ -629,7 +629,8 @@ def dao_fetch_stats_for_service_from_days_for_user(
|
||||
).group_by(total_substmt.c.hour)
|
||||
|
||||
total_notifications = {
|
||||
row.hour: row.total_notifications for row in db.session.execute(total_stmt).all()
|
||||
row.hour: row.total_notifications
|
||||
for row in db.session.execute(total_stmt).all()
|
||||
}
|
||||
|
||||
stmt = (
|
||||
|
||||
Reference in New Issue
Block a user