 
 extension IAPManager: SKPaymentTransactionObserver {
     
-    func paymentQueue(queue: SKPaymentQueue!, updatedTransactions transactions: [AnyObject]!) {
-        if let paymentTransactions = transactions as? [SKPaymentTransaction] {
-            for transaction in paymentTransactions {
-                let productId = transaction.payment.productIdentifier
-                switch transaction.transactionState {
-                case .Restored: fallthrough
-                case .Purchased:
-                    purchasedProductIds.append(productId)
-                    savePurchasedItems()
-                    
-                    callPurchaseProductCompletionForProduct(productId, error: nil)
-                    queue.finishTransaction(transaction)
-                case .Failed:
-                    callPurchaseProductCompletionForProduct(productId, error: transaction.error)
-                    queue.finishTransaction(transaction)
-                case .Purchasing:
-                    println("Purchasing \(productId)...")
-                default: break
-                }
-            }
-        }
-    }
-    
-    func paymentQueueRestoreCompletedTransactionsFinished(queue: SKPaymentQueue!) {
+    func paymentQueue(queue: SKPaymentQueue, updatedTransactions transactions: [SKPaymentTransaction]) {
+        for transaction in transactions {
+            let productId = transaction.payment.productIdentifier
+            switch transaction.transactionState {
+            case .Restored: fallthrough
+            case .Purchased:
+                purchasedProductIds.append(productId)
+                savePurchasedItems()
+                
+                callPurchaseProductCompletionForProduct(productId, error: nil)
+                queue.finishTransaction(transaction)
+            case .Failed:
+                callPurchaseProductCompletionForProduct(productId, error: transaction.error)
+                queue.finishTransaction(transaction)
+            case .Purchasing:
+                print("Purchasing \(productId)...")
+            default: break
+            }
+        }
+    }
+    
+    func paymentQueueRestoreCompletedTransactionsFinished(queue: SKPaymentQueue) {
         if let completion = restoreTransactionsCompletionBlock {
             completion(nil)
         }
     }
     
-    func paymentQueue(queue: SKPaymentQueue!, restoreCompletedTransactionsFailedWithError error: NSError!) {
+    func paymentQueue(queue: SKPaymentQueue, restoreCompletedTransactionsFailedWithError error: NSError) {
         if let completion = restoreTransactionsCompletionBlock {
             completion(error)
         }

    
    private func callLoadProductsCompletionForRequest(request: SKProductsRequest, responseProducts:Array<SKProduct>?, error: NSError?) {
        dispatch_async(dispatch_get_main_queue()) {
            for i in 0..<count(self.loadProductsRequests) {
                let requestInfo = self.loadProductsRequests[i]
                if requestInfo.request == request {
                    self.loadProductsRequests.removeAtIndex(i)

            }
        }
        
        if remainingIds.count == 0 {
            completion(loadedProducts, nil)
        }
        
