Fix cache injection settings

This commit is contained in:
2025-06-25 19:50:19 -06:00
parent 5697922eca
commit b9c1f794e0
3 changed files with 6 additions and 10 deletions

View File

@@ -6,18 +6,17 @@ using Core.Blueprint.DAL.SQLServer.Entities.Request;
using Core.Blueprint.Redis;
using Core.Blueprint.Redis.Helpers;
using Mapster;
using Microsoft.Extensions.Options;
public class SqlSampleService : ISqlSampleService
{
private readonly IEntityRepository<Sample, SqlServerContext> _sqlSampleRepository;
private readonly CacheSettings cacheSettings;
private readonly ICacheSettings cacheSettings;
private readonly IRedisCacheProvider cacheProvider;
public SqlSampleService(IEntityRepository<Sample, SqlServerContext> sqlSampleRepository, IRedisCacheProvider cacheProvider, IOptions<CacheSettings> cacheSettings)
public SqlSampleService(IEntityRepository<Sample, SqlServerContext> sqlSampleRepository, IRedisCacheProvider cacheProvider, ICacheSettings cacheSettings)
{
_sqlSampleRepository = sqlSampleRepository;
this.cacheSettings = cacheSettings.Value;
this.cacheSettings = cacheSettings;
this.cacheProvider = cacheProvider;
}