From 0b849b6a919eb820bc04bc2c9dff073b1b2f2279 Mon Sep 17 00:00:00 2001 From: Patrick Fic Date: Wed, 3 Feb 2021 11:38:18 -0800 Subject: [PATCH] Added null handling for phone formatter IO-483 --- client/src/utils/PhoneFormatter.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/utils/PhoneFormatter.jsx b/client/src/utils/PhoneFormatter.jsx index 6128760c8..d99922697 100644 --- a/client/src/utils/PhoneFormatter.jsx +++ b/client/src/utils/PhoneFormatter.jsx @@ -3,6 +3,6 @@ import parsePhoneNumber from "libphonenumber-js"; import React from "react"; export default function PhoneNumberFormatter(props) { - const p = parsePhoneNumber(props.children, "CA"); + const p = parsePhoneNumber(props.children || "", "CA"); return p ? {p.formatInternational()} : null; }