Browse Source

Improvements swift code

Marino Faggiana 8 years ago
parent
commit
06d5f830f9
1 changed files with 1 additions and 8 deletions
  1. 1 8
      Picker/DocumentPickerViewController.swift

+ 1 - 8
Picker/DocumentPickerViewController.swift

@@ -676,14 +676,7 @@ extension DocumentPickerViewController: UITableViewDataSource {
     
     func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
         
-        if (recordsTableMetadata == nil) {
-            
-            return 0
-            
-        } else {
-            
-            return recordsTableMetadata!.count
-        }
+       return recordsTableMetadata?.count ?? 0
     }
         
     func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {