Skip to content

Commit

Permalink
fix task canceled exceptions with CoTask used in command, CallMethodA…
Browse files Browse the repository at this point in the history
…ction and EventAggregator
  • Loading branch information
tibel committed Aug 26, 2014
1 parent 45bc81d commit 6ab2d30
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 7 deletions.
5 changes: 2 additions & 3 deletions nuget/Caliburn.Light.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<metadata>
<id>Caliburn.Light</id>
<title>Caliburn.Light</title>
<version>1.6.0</version>
<version>1.6.1</version>
<authors>Thomas Ibel</authors>
<description>The magic-free Caliburn.Light, a powerful framework designed for building applications across all XAML platforms.</description>
<language>en-US</language>
Expand All @@ -12,8 +12,7 @@
<iconUrl>https://github.com/tibel/Caliburn.Light/raw/master/logo.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<releaseNotes>
- async CanClose handling (ICloseGuard and ICloseStrategy)
- propagate exceptions from async methods
Bugfixes
</releaseNotes>
<copyright>Copyright Thomas Ibel 2014</copyright>
<tags>Caliburn MVVM WPF WP8 Win8 WinRT Screen Coroutine EventAggregator Behavior Model-View-ViewModel Presentation UI ViewModel Phone IoC Validation Command Async</tags>
Expand Down
2 changes: 1 addition & 1 deletion src/Caliburn.Core/Action/DelegateCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ public void Execute(object parameter)

var coTask = returnValue as ICoTask;
if (coTask != null)
returnValue = coTask.ExecuteAsync(context);
returnValue = coTask.OverrideCancel().ExecuteAsync(context);

var task = returnValue as Task;
if (task != null)
Expand Down
2 changes: 1 addition & 1 deletion src/Caliburn.Core/EventAggregator/EventAggregator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ public void Invoke(object message)
Target = target,
};

returnValue = coTask.ExecuteAsync(context);
returnValue = coTask.OverrideCancel().ExecuteAsync(context);
}

var task = returnValue as Task;
Expand Down
2 changes: 1 addition & 1 deletion src/Caliburn.Xaml/Behaviors/CallMethodAction.cs
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ protected override void Invoke(object parameter)

var coTask = returnValue as ICoTask;
if (coTask != null)
returnValue = coTask.ExecuteAsync(context);
returnValue = coTask.OverrideCancel().ExecuteAsync(context);

var task = returnValue as Task;
if (task != null)
Expand Down
2 changes: 1 addition & 1 deletion src/GlobalAssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@
#endif

[assembly: AssemblyVersion("1.6.0.0")]
[assembly: AssemblyFileVersion("1.6.0.0")]
[assembly: AssemblyFileVersion("1.6.1.0")]

0 comments on commit 6ab2d30

Please sign in to comment.