Open asifbilal786 opened 5 years ago
Hi
First thanks for the great library. It's really useful.
But I am facing the memory leaks when using this library. I have debug into the code and came to know that this code is causing memory leak.
self.propertyAnimator = [[UIViewPropertyAnimator alloc] initWithDuration:1.0 curve:UIViewAnimationCurveLinear animations:^{ self.blurBackgroundView.effect = nil; }];
To resolve it I have changed it to weak self as instructed by Apple to avoid any memory issue.
__weak MZFormSheetPresentationController *weakSelf = self; self.propertyAnimator = [[UIViewPropertyAnimator alloc] initWithDuration:1.0 curve:UIViewAnimationCurveLinear animations:^{ weakSelf.blurBackgroundView.effect = nil; }];
Please update the pod with resolution of this issue. Thanks!!!
Thanks, thats true, this is a memory leak, can you make PR ?
I have created Pull Request for this issue. Please accept this.
Don't see Pull Request, you probably only have added commit to your repo
Hi
First thanks for the great library. It's really useful.
But I am facing the memory leaks when using this library. I have debug into the code and came to know that this code is causing memory leak.
self.propertyAnimator = [[UIViewPropertyAnimator alloc] initWithDuration:1.0 curve:UIViewAnimationCurveLinear animations:^{ self.blurBackgroundView.effect = nil; }];
To resolve it I have changed it to weak self as instructed by Apple to avoid any memory issue.
__weak MZFormSheetPresentationController *weakSelf = self; self.propertyAnimator = [[UIViewPropertyAnimator alloc] initWithDuration:1.0 curve:UIViewAnimationCurveLinear animations:^{ weakSelf.blurBackgroundView.effect = nil; }];
Please update the pod with resolution of this issue. Thanks!!!