         switch section {
         case 0:
 
-            if items.count == 0 {
+            if let items = items {
+                return pageToken == nil ? items.count : items.count + 1
+            } else {
                 return 1
             }
 
-            return pageToken == nil ? items.count : items.count + 1
-
         default:
 
             return 0

    var pageToken: String?
    var storeOptions: StorageOptions!

    private var items: [CloudItem] = [CloudItem]()
    private var currentRequest: CancellableRequest?

    private let thumbnailCache: NSCache<NSURL, UIImage> = {


    override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {

        guard let item = items?[safe: UInt(indexPath.row)] else { return }

        if item.isFolder {
            let scene = CloudSourceDetailScene(filestack: filestack,
