Skip to content

Commit 6409f8b

Browse files
Remove unused _contextAccessor field from controllers (#672)
1 parent ce2390d commit 6409f8b

File tree

4 files changed

+0
-16
lines changed

4 files changed

+0
-16
lines changed

src/Web/Grand.Web.Admin/Controllers/PaymentTransactionController.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
using Grand.Business.Core.Queries.Checkout.Orders;
77
using Grand.Domain.Payments;
88
using Grand.Domain.Permissions;
9-
using Grand.Infrastructure;
109
using Grand.SharedKernel;
1110
using Grand.Web.AdminShared.Models.Orders;
1211
using Grand.Web.Common.DataSource;
@@ -27,15 +26,13 @@ public PaymentTransactionController(
2726
ITranslationService translationService,
2827
IPaymentTransactionService paymentTransactionService,
2928
IOrderService orderService,
30-
IContextAccessor contextAccessor,
3129
IDateTimeService dateTimeService,
3230
IMediator mediator,
3331
IEnumTranslationService enumTranslationService)
3432
{
3533
_translationService = translationService;
3634
_paymentTransactionService = paymentTransactionService;
3735
_orderService = orderService;
38-
_contextAccessor = contextAccessor;
3936
_dateTimeService = dateTimeService;
4037
_mediator = mediator;
4138
_enumTranslationService = enumTranslationService;
@@ -48,7 +45,6 @@ public PaymentTransactionController(
4845
private readonly IPaymentTransactionService _paymentTransactionService;
4946
private readonly IOrderService _orderService;
5047
private readonly ITranslationService _translationService;
51-
private readonly IContextAccessor _contextAccessor;
5248
private readonly IDateTimeService _dateTimeService;
5349
private readonly IMediator _mediator;
5450
private readonly IEnumTranslationService _enumTranslationService;

src/Web/Grand.Web.Admin/Controllers/ProductAttributeController.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
using Grand.Business.Core.Interfaces.Common.Localization;
44
using Grand.Domain.Permissions;
55
using Grand.Domain.Seo;
6-
using Grand.Infrastructure;
76
using Grand.Web.AdminShared.Extensions.Mapping;
87
using Grand.Web.AdminShared.Models.Catalog;
98
using Grand.Web.Common.DataSource;
@@ -23,14 +22,12 @@ public ProductAttributeController(
2322
IProductAttributeService productAttributeService,
2423
ILanguageService languageService,
2524
ITranslationService translationService,
26-
IContextAccessor contextAccessor,
2725
SeoSettings seoSettings)
2826
{
2927
_productService = productService;
3028
_productAttributeService = productAttributeService;
3129
_languageService = languageService;
3230
_translationService = translationService;
33-
_contextAccessor = contextAccessor;
3431
_seoSettings = seoSettings;
3532
}
3633

@@ -42,7 +39,6 @@ public ProductAttributeController(
4239
private readonly IProductAttributeService _productAttributeService;
4340
private readonly ILanguageService _languageService;
4441
private readonly ITranslationService _translationService;
45-
private readonly IContextAccessor _contextAccessor;
4642
private readonly SeoSettings _seoSettings;
4743

4844
#endregion Fields

src/Web/Grand.Web.Admin/Controllers/SpecificationAttributeController.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
using Grand.Business.Core.Interfaces.Common.Localization;
44
using Grand.Domain.Permissions;
55
using Grand.Domain.Seo;
6-
using Grand.Infrastructure;
76
using Grand.Web.AdminShared.Extensions.Mapping;
87
using Grand.Web.AdminShared.Models.Catalog;
98
using Grand.Web.Common.DataSource;
@@ -22,14 +21,12 @@ public SpecificationAttributeController(
2221
ISpecificationAttributeService specificationAttributeService,
2322
ILanguageService languageService,
2423
ITranslationService translationService,
25-
IContextAccessor contextAccessor,
2624
IProductService productService,
2725
SeoSettings seoSettings)
2826
{
2927
_specificationAttributeService = specificationAttributeService;
3028
_languageService = languageService;
3129
_translationService = translationService;
32-
_contextAccessor = contextAccessor;
3330
_productService = productService;
3431
_seoSettings = seoSettings;
3532
}
@@ -96,7 +93,6 @@ public async Task<IActionResult> UsedByProducts(DataSourceRequest command, strin
9693
private readonly IProductService _productService;
9794
private readonly ILanguageService _languageService;
9895
private readonly ITranslationService _translationService;
99-
private readonly IContextAccessor _contextAccessor;
10096
private readonly SeoSettings _seoSettings;
10197

10298
#endregion Fields

src/Web/Grand.Web.Vendor/Controllers/HomeController.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
using Grand.Business.Core.Interfaces.Common.Directory;
33
using Grand.Business.Core.Interfaces.Common.Localization;
44
using Grand.Domain.Directory;
5-
using Grand.Infrastructure;
65
using Microsoft.AspNetCore.Mvc;
76

87
namespace Grand.Web.Vendor.Controllers;
@@ -12,11 +11,9 @@ public class HomeController : BaseVendorController
1211
#region Ctor
1312

1413
public HomeController(
15-
IContextAccessor contextAccessor,
1614
ILogger<HomeController> logger,
1715
IGrandAuthenticationService authenticationService)
1816
{
19-
_contextAccessor = contextAccessor;
2017
_logger = logger;
2118
_authenticationService = authenticationService;
2219
}
@@ -25,7 +22,6 @@ public HomeController(
2522

2623
#region Fields
2724

28-
private readonly IContextAccessor _contextAccessor;
2925
private readonly ILogger<HomeController> _logger;
3026
private readonly IGrandAuthenticationService _authenticationService;
3127

0 commit comments

Comments
 (0)