     }
 
     private func refreshData() {
-        guard let refreshDataBlock = refreshDataBlock else {
-            return
-        }
         refreshDataBlock()
     }
 

            self?.dataItem.append(item)
            self?.refreshData()
        }, onError: { [unowned self] (error) in
            self.onErrorBlock?(error)
        }).disposed(by: disposeBag)
    }


    typealias OnErrorBlock = (_ error: Error) -> Void

    // MARK: - Fields
    var refreshDataBlock: RefreshDataBlock = {
    }

    var onErrorBlock: OnErrorBlock = { _ in
    }

    private let itemsSubject = PublishSubject<I>()

    private let dataItem: S
