EF7 npgsql => ko aux clients => inutile en lib [obsdnx]
This commit is contained in:
22
Yavsc/Services/SIRENCheker.cs
Normal file
22
Yavsc/Services/SIRENCheker.cs
Normal file
@ -0,0 +1,22 @@
|
||||
using System.Net.Http;
|
||||
using System.Threading.Tasks;
|
||||
using Yavsc.Helpers;
|
||||
|
||||
namespace Yavsc.Services
|
||||
{
|
||||
using Models.societe.com;
|
||||
public class SIRENChecker
|
||||
{
|
||||
private CompanyInfoSettings _settings;
|
||||
public SIRENChecker(CompanyInfoSettings settings)
|
||||
{
|
||||
_settings = settings;
|
||||
}
|
||||
public async Task<CompanyInfoMessage> CheckAsync(string siren) {
|
||||
using (var web = new HttpClient())
|
||||
{
|
||||
return await web.CheckSiren(siren, _settings);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user