marinofaggiana 4 years ago
parent
commit
e36dc197be
2 changed files with 4 additions and 4 deletions
  1. 2 2
      iOSClient/Main/NCCollectionCommon.swift
  2. 2 2
      iOSClient/Select/NCSelect.swift

+ 2 - 2
iOSClient/Main/NCCollectionCommon.swift

@@ -1020,7 +1020,7 @@ extension NCCollectionViewCommon: UICollectionViewDataSource {
     }
     
     func numberOfSections(in collectionView: UICollectionView) -> Int {
-        return dataSource?.sections ?? 1
+        return 1
     }
     
     func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
@@ -1067,7 +1067,7 @@ extension NCCollectionViewCommon: UICollectionViewDelegateFlowLayout {
     }
     
     func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, referenceSizeForFooterInSection section: Int) -> CGSize {
-        let sections = dataSource?.sections ?? 1
+        let sections = 1
         if (section == sections - 1) {
             return CGSize(width: collectionView.frame.width, height: footerHeight)
         } else {

+ 2 - 2
iOSClient/Select/NCSelect.swift

@@ -455,7 +455,7 @@ extension NCSelect: UICollectionViewDataSource {
     }
     
     func numberOfSections(in collectionView: UICollectionView) -> Int {
-        return dataSource?.sections ?? 1
+        return 1
     }
     
     func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
@@ -508,7 +508,7 @@ extension NCSelect: UICollectionViewDelegateFlowLayout {
     }
     
     func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, referenceSizeForFooterInSection section: Int) -> CGSize {
-        let sections = dataSource?.sections ?? 1
+        let sections = 1
         if (section == sections - 1) {
             return CGSize(width: collectionView.frame.width, height: footerHeight)
         } else {