Skip to content

Commit

Permalink
Fix: Formating list of errors
Browse files Browse the repository at this point in the history
  • Loading branch information
altmann committed Oct 30, 2021
1 parent 00c83f7 commit 4158772
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ public class ErrorListValueFormatter : IValueFormatter
{
public bool CanHandle(object value)
{
return value is List<Error>;
return value is List<IError>;
}

public void Format(object value, FormattedObjectGraph formattedGraph, FormattingContext context, FormatChild formatChild)
{
var errors = (IEnumerable<Error>)value;
var errors = (IEnumerable<IError>)value;
formattedGraph.AddFragment(string.Join("; ", errors.Select(error => error.Message)));
}
}
Expand Down

0 comments on commit 4158772

Please sign in to comment.