feat: implement analyzer and code fixer for identifying and fixing when a sync flag is not propagated correctly.
This commit is contained in:
+20
@@ -0,0 +1,20 @@
|
||||
using System.Threading.Tasks;
|
||||
|
||||
public interface IDataService
|
||||
{
|
||||
Task<string> GetDataAsync(bool sync = false);
|
||||
Task<string> GetMoreDataAsync(bool sync = false);
|
||||
}
|
||||
|
||||
public class BusinessLogic
|
||||
{
|
||||
private readonly IDataService _dataService;
|
||||
public BusinessLogic(IDataService dataService) { _dataService = dataService; }
|
||||
|
||||
private async Task<string> GetFrobCoreAsync(bool sync)
|
||||
{
|
||||
var a = await _dataService.GetDataAsync(sync);
|
||||
var b = await {|#0:_dataService.GetMoreDataAsync()|};
|
||||
return a + b;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user