Skip to content

Commit b92fb1c

Browse files
committed
use preallocated phoneNumberKit
1 parent 4516121 commit b92fb1c

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Tinodios/SettingsPersonalViewController.swift

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ class SettingsPersonalViewController: UITableViewController {
3434
weak var me: DefaultMeTopic!
3535
private var imagePicker: ImagePicker!
3636

37-
private let phoneNumberKit = PhoneNumberKit()
38-
3937
override func viewDidLoad() {
4038
super.viewDidLoad()
4139
setup()
@@ -180,8 +178,8 @@ extension SettingsPersonalViewController {
180178

181179
var contact = cred.val
182180
if cred.meth == "tel", let tel = contact {
183-
if let number = try? phoneNumberKit.parse(tel) {
184-
contact = phoneNumberKit.format(number, toType: .international)
181+
if let number = try? Utils.phoneNumberKit.parse(tel) {
182+
contact = Utils.phoneNumberKit.format(number, toType: .international)
185183
}
186184
}
187185
cell.textLabel?.text = contact

0 commit comments

Comments
 (0)