     }
     
     override open var collectionViewContentSize: CGSize {
-        let viewSize = collectionView?.bounds.size
+        guard let collectionView = collectionView else { return CGSize.zero }
+        let viewSize = collectionView.bounds.size
         var visibleCellCount:CGFloat
         var contentSize:CGSize
         switch configuration.wheelType {
         case .bottomCenter,.topCenter,.rightCenter,.leftCenter:
             visibleCellCount = CGFloat(180.0/configuration.angular+1.0)
-            contentSize = CGSize.init(width: viewSize!.width,
-                                      height: (viewSize?.height)!+(CGFloat(cellCount)-visibleCellCount)*(configuration.cellSize.height)+CGFloat(configuration.contentHeigthPadding))
+            contentSize = CGSize.init(width: viewSize.width,
+                                      height: (viewSize.height)+(CGFloat(cellCount)-visibleCellCount)*(configuration.cellSize.height)+CGFloat(configuration.contentHeigthPadding))
         default:
             visibleCellCount = CGFloat(90.0/configuration.angular+1.0)
-            contentSize = CGSize.init(width: viewSize!.width,
-                                      height: (viewSize?.height)!+(CGFloat(cellCount)-visibleCellCount)*(configuration.cellSize.height)+CGFloat(configuration.contentHeigthPadding))
+            contentSize = CGSize.init(width: viewSize.width,
+                                      height: (viewSize.height)+(CGFloat(cellCount)-visibleCellCount)*(configuration.cellSize.height)+CGFloat(configuration.contentHeigthPadding))
         }
         
         return contentSize

            }
            
        case .rightCenter:
            attributes.center = CGPoint.init(x: (viewSize?.width)!-cellSize.width/2.0,
                                             y: (contentOffset?.y)!+(viewSize?.height)!/2)
            
            if (angle <= (M_PI+2.0*angleOffset+angular/180.0)) && (angle >= -angleOffset) {
                attributes.isHidden = false

                                                     y: (CGFloat(sin(angle)*radius)))
            }
        case .bottomCenter:
            attributes.center = CGPoint.init(x: (viewSize.width)/2.0,
                                             y: (contentOffset.y)+(viewSize.height)-cellSize.height/2)
            angle = visibleCellIndex*angular/180*M_PI;
            
            if (angle <= (M_PI+2.0*angleOffset+angular/180.0)) && (angle >= -angleOffset) {
