Skip to content
This repository was archived by the owner on Nov 17, 2023. It is now read-only.

Commit 81e4312

Browse files
Small Refactoring (#1558)
1 parent c3d91dd commit 81e4312

18 files changed

+19
-80
lines changed

src/Web/WebhookClient/Controllers/WebhooksReceivedController.cs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
using Microsoft.AspNetCore.Http;
2-
using Microsoft.AspNetCore.Mvc;
1+
using Microsoft.AspNetCore.Mvc;
32
using Microsoft.Extensions.Logging;
43
using Microsoft.Extensions.Options;
5-
using System;
6-
using System.Collections.Generic;
74
using System.Linq;
85
using System.Threading.Tasks;
96
using WebhookClient.Models;
@@ -19,7 +16,7 @@ public class WebhooksReceivedController : Controller
1916
private readonly Settings _settings;
2017
private readonly ILogger _logger;
2118
private readonly IHooksRepository _hooksRepository;
22-
19+
2320
public WebhooksReceivedController(IOptions<Settings> settings, ILogger<WebhooksReceivedController> logger, IHooksRepository hooksRepository)
2421
{
2522
_settings = settings.Value;

src/Web/WebhookClient/HeaderNames.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Threading.Tasks;
5-
6-
namespace WebhookClient
1+
namespace WebhookClient
72
{
83
static class HeaderNames
94
{

src/Web/WebhookClient/HttpClientAuthorizationDelegatingHandler.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
using Microsoft.AspNetCore.Authentication;
22
using Microsoft.AspNetCore.Http;
3-
using System;
43
using System.Collections.Generic;
5-
using System.Linq;
64
using System.Net.Http;
75
using System.Net.Http.Headers;
86
using System.Threading;

src/Web/WebhookClient/Models/WebHookReceived.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Threading.Tasks;
52

63
namespace WebhookClient.Models
74
{
85
public class WebHookReceived
96
{
107
public DateTime When { get; set; }
8+
119
public string Data { get; set; }
1210

1311
public string Token { get; set; }

src/Web/WebhookClient/Models/WebhookData.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Threading.Tasks;
52

63
namespace WebhookClient.Models
74
{

src/Web/WebhookClient/Models/WebhookResponse.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Threading.Tasks;
52

63
namespace WebhookClient.Models
74
{

src/Web/WebhookClient/Models/WebhookSubscriptionRequest.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Threading.Tasks;
5-
6-
namespace WebhookClient.Models
1+
namespace WebhookClient.Models
72
{
83
public class WebhookSubscriptionRequest
94
{

src/Web/WebhookClient/Pages/Error.cshtml.cs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Diagnostics;
4-
using System.Linq;
5-
using System.Threading.Tasks;
61
using Microsoft.AspNetCore.Mvc;
72
using Microsoft.AspNetCore.Mvc.RazorPages;
3+
using System.Diagnostics;
84

95
namespace WebhookClient.Pages
106
{

src/Web/WebhookClient/Pages/Index.cshtml.cs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
1-
using System;
1+
using Microsoft.AspNetCore.Mvc.RazorPages;
22
using System.Collections.Generic;
3-
using System.Linq;
43
using System.Threading.Tasks;
5-
using Microsoft.AspNetCore.Mvc;
6-
using Microsoft.AspNetCore.Mvc.RazorPages;
7-
using Microsoft.AspNetCore.Http;
84
using WebhookClient.Models;
95
using WebhookClient.Services;
106

src/Web/WebhookClient/Pages/Privacy.cshtml.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Threading.Tasks;
5-
using Microsoft.AspNetCore.Mvc;
6-
using Microsoft.AspNetCore.Mvc.RazorPages;
1+
using Microsoft.AspNetCore.Mvc.RazorPages;
72

83
namespace WebhookClient.Pages
94
{

0 commit comments

Comments
 (0)