From 75014f522bf55e789fb2fccfd572c85854c21d9c Mon Sep 17 00:00:00 2001 From: Paolo Musolino Date: Tue, 16 Jan 2018 15:22:15 +0100 Subject: [PATCH] - weak self in DispatchQueue.main.asyncAfter - version bump --- Library/PMAlertAction.swift | 4 ++-- PMAlertController.podspec | 2 +- PMAlertController/Info.plist | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Library/PMAlertAction.swift b/Library/PMAlertAction.swift index 539b37a..8aa3d70 100644 --- a/Library/PMAlertAction.swift +++ b/Library/PMAlertAction.swift @@ -48,8 +48,8 @@ import UIKit @objc func tapped(_ sender: PMAlertAction) { //Action need to be fired after alert dismiss - DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) { - self.action?() + DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) { [weak self] in + self?.action?() } } diff --git a/PMAlertController.podspec b/PMAlertController.podspec index 515c74f..554d23e 100644 --- a/PMAlertController.podspec +++ b/PMAlertController.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = "PMAlertController" - s.version = "3.1.0" + s.version = "3.2.0" s.summary = "PMAlertController is a great and customizable substitute to UIAlertController" s.description = <<-DESC PMAlertController is a small library that allows you to substitute the uncustomizable UIAlertController of Apple, with a beautiful and totally customizable alert that you can use in your iOS app. Enjoy! diff --git a/PMAlertController/Info.plist b/PMAlertController/Info.plist index c55681f..fdab7e3 100644 --- a/PMAlertController/Info.plist +++ b/PMAlertController/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 3.1.0 + 3.2.0 CFBundleSignature ???? CFBundleVersion