     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 {

                    outerScrollView.alwaysBounceVertical = true
                }
            }
            nestedScrollView.isScrollEnabled = isNestedScrollEnabled
        } else {
            if scrollView.contentOffset.y <= 0 {
                if nestedScrollView.bounces {
                    nestedScrollView.bounces = false
                    nestedScrollView.alwaysBounceVertical = false

    }

    func nestedTransferVelocity(_ velocity: CGFloat) {
        if velocity > 0.0 {
            return
        }
        self.nestedDeceleration?.isPaused = true
        let startTime = CACurrentMediaTime()
        let scrollView = outerScrollView
        var currentOffset = scrollView.contentOffset
        let decelerationRate = outerScrollView.decelerationRate.rawValue
        scrollViewDidEndDragging(scrollView, willDecelerate: true)
        self.nestedDeceleration = ConstantDisplayLinkAnimator(update: { [weak self] in
            guard let strongSelf = self else {
                return
