Skip to content

Commit

Permalink
positive loss sum
Browse files Browse the repository at this point in the history
  • Loading branch information
JohanLarsson committed Mar 20, 2024
1 parent f71163d commit dd56c4c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion IbkrToSru/MainViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public sealed class MainViewModel : System.ComponentModel.INotifyPropertyChanged

public string LossSum => this.executions.IsDefaultOrEmpty
? string.Empty
: new ExchangeRate("USD", this.exchangeRate).ToSekText(this.executions.Sum(x => Math.Min(x.Pnl, 0)));
: new ExchangeRate("USD", this.exchangeRate).ToSekText(-this.executions.Sum(x => Math.Min(x.Pnl, 0)));

public string SruText
{
Expand Down

0 comments on commit dd56c4c

Please sign in to comment.