From a63a3cfc148d10265ef449ea55603373651ec374 Mon Sep 17 00:00:00 2001 From: Keith Harrison Date: Sat, 29 Oct 2011 20:17:41 +0100 Subject: [PATCH] Remove observer when view is deallocated --- SyncMe/SyncMe/UYLViewController.m | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/SyncMe/SyncMe/UYLViewController.m b/SyncMe/SyncMe/UYLViewController.m index 98d2f3e..fd7177d 100644 --- a/SyncMe/SyncMe/UYLViewController.m +++ b/SyncMe/SyncMe/UYLViewController.m @@ -93,6 +93,11 @@ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interface return YES; } +- (void)dealloc { + [[NSNotificationCenter defaultCenter] removeObserver:self]; + [super dealloc]; +} + #pragma mark - #pragma mark === Button Action === #pragma mark -