summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Core
diff options
context:
space:
mode:
authoradrianknight89 <adrianknight89@outlook.com>2016-11-24 19:34:46 (GMT)
committerStephane Delcroix <stephane@delcroix.org>2016-11-24 19:34:46 (GMT)
commit1f3d5ecd260c836563b34efe2be3f8e287582eaf (patch)
tree640e183debe00384e74b7c35a169417c136ec869 /Xamarin.Forms.Core
parent57152381377d2b09f749f46b829add58f1ab1930 (diff)
downloadxamarin-forms-1f3d5ecd260c836563b34efe2be3f8e287582eaf.zip
xamarin-forms-1f3d5ecd260c836563b34efe2be3f8e287582eaf.tar.gz
xamarin-forms-1f3d5ecd260c836563b34efe2be3f8e287582eaf.tar.bz2
fix weakreferences (#558)
Diffstat (limited to 'Xamarin.Forms.Core')
-rw-r--r--Xamarin.Forms.Core/MessagingCenter.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Xamarin.Forms.Core/MessagingCenter.cs b/Xamarin.Forms.Core/MessagingCenter.cs
index 973531a..0efb3a3 100644
--- a/Xamarin.Forms.Core/MessagingCenter.cs
+++ b/Xamarin.Forms.Core/MessagingCenter.cs
@@ -91,7 +91,7 @@ namespace Xamarin.Forms
List<Tuple<WeakReference, Action<object, object>>> actionsCopy = actions.ToList();
foreach (Tuple<WeakReference, Action<object, object>> action in actionsCopy)
{
- if (action.Item1.IsAlive && actions.Contains(action))
+ if (action.Item1.Target != null && actions.Contains(action))
action.Item2(sender, args);
}
}