Skip to content

Commit a3d94df

Browse files
authored
Merge pull request #31 from chrisbrandow/chrisbrandow-patch-1
Fix `dismissWithDelay` method
2 parents 84b6536 + 12fc746 commit a3d94df

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/IHProgressHUD/IHProgressHUD.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -626,7 +626,7 @@ public class IHProgressHUD : UIView {
626626
// values to check if an animation is necessary. The evaluation happens at function call time and not
627627
// after the delay => the animation is sometimes skipped. Therefore we delay using dispatch_after.
628628

629-
let dipatchTime = DispatchTime.now() + Double(Int64(delay * Double(NSEC_PER_SEC)))
629+
let dipatchTime = DispatchTime.now() + delay
630630
DispatchQueue.main.asyncAfter(deadline: dipatchTime, execute: {
631631
if strongSelf.fadeOutAnimationDuration > 0 {
632632
UIView.animate(withDuration: strongSelf.fadeOutAnimationDuration, delay: 0, options: [.allowUserInteraction, .curveEaseOut, .beginFromCurrentState], animations: {

0 commit comments

Comments
 (0)