class Playbook::PbContact::Contact
def formatted_contact_value
def formatted_contact_value if contact_type == "email" contact_value elsif contact_type == "extension" && contact_value.match(/^\d{4}$/) contact_value else number_to_phone(formatted_value, area_code: true) end end