     func scrollViewDidScroll(_ scrollView: UIScrollView) {
         velocityM1 = velocity
         velocity = scrollView.value(forKey: "_verticalVelocity") as? CGFloat ?? 0
+        nestedScrollView.isScrollEnabled = isNestedScrollEnabled
         if scrollView == outerScrollView {
             if scrollView.contentOffset.y > 50 {
                 if outerScrollView.bounces {

            let t = CACurrentMediaTime() - startTime
            var currentVelocity = velocity * 15.0 * CGFloat(pow(Double(decelerationRate), 1000.0 * t))
            currentOffset.y += currentVelocity
            let maxOffset = strongSelf.outerScrollView.contentSize.height - strongSelf.outerScrollView.bounds.height
            if currentOffset.y >= maxOffset {
                currentOffset.y = maxOffset
                currentVelocity = 0.0

                strongSelf.nestedDeceleration = nil
                didEnd = true
            }
            var contentOffset = scrollView.contentOffset
            contentOffset.y = currentOffset.y.flat
            scrollView.setContentOffset(contentOffset, animated: false)
            strongSelf.scrollViewDidScroll(scrollView)
            if didEnd {
                strongSelf.scrollViewDidEndDecelerating(scrollView)
            }
        })
        self.nestedDeceleration?.isPaused = false
