mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-07-09 03:04:19 -04:00
Reading List Bug (#1943)
* Refactored how we calculate start and end dates for a reading list generated from Scan. * Cleaned up the logging messages a bit * By default, allow DB statements to include params, since there's no PPI involved.
This commit is contained in:
parent
868d20a18e
commit
19198beadf
@ -70,7 +70,8 @@ public static class ApplicationServiceExtensions
|
||||
{
|
||||
options.UseSqlite("Data source=config/kavita.db");
|
||||
options.EnableDetailedErrors();
|
||||
options.EnableSensitiveDataLogging(env.IsDevelopment());
|
||||
|
||||
options.EnableSensitiveDataLogging();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -297,7 +297,7 @@ public class ReadingListService : IReadingListService
|
||||
/// <summary>
|
||||
/// Calculates the Start month/year and Ending month/year
|
||||
/// </summary>
|
||||
/// <param name="readingListWithItems">Reading list should have all items</param>
|
||||
/// <param name="readingListWithItems">Reading list should have all items and Chapters</param>
|
||||
public async Task CalculateStartAndEndDates(ReadingList readingListWithItems)
|
||||
{
|
||||
var items = readingListWithItems.Items;
|
||||
@ -497,11 +497,12 @@ public class ReadingListService : IReadingListService
|
||||
|
||||
readingList.Items = items;
|
||||
await CalculateReadingListAgeRating(readingList);
|
||||
await CalculateStartAndEndDates(readingList);
|
||||
if (_unitOfWork.HasChanges())
|
||||
{
|
||||
await _unitOfWork.CommitAsync();
|
||||
}
|
||||
await CalculateStartAndEndDates(await _unitOfWork.ReadingListRepository.GetReadingListByTitleAsync(arcPair.Item1, user.Id, ReadingListIncludes.Items | ReadingListIncludes.ItemChapter));
|
||||
await _unitOfWork.CommitAsync();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -500,7 +500,6 @@ public class ProcessSeries : IProcessSeries
|
||||
_logger.LogDebug("[ScannerService] Updating {DistinctVolumes} volumes on {SeriesName}", distinctVolumes.Count, series.Name);
|
||||
foreach (var volumeNumber in distinctVolumes)
|
||||
{
|
||||
_logger.LogTrace("[ScannerService] Looking up volume for {VolumeNumber}", volumeNumber);
|
||||
Volume? volume;
|
||||
try
|
||||
{
|
||||
|
@ -304,8 +304,11 @@ public static class Configuration
|
||||
private sealed class AppSettings
|
||||
{
|
||||
public string TokenKey { get; set; }
|
||||
// ReSharper disable once MemberHidesStaticFromOuterClass
|
||||
public int Port { get; set; }
|
||||
// ReSharper disable once MemberHidesStaticFromOuterClass
|
||||
public string IpAddresses { get; set; }
|
||||
// ReSharper disable once MemberHidesStaticFromOuterClass
|
||||
public string BaseUrl { get; set; }
|
||||
}
|
||||
}
|
||||
|
@ -7,7 +7,7 @@
|
||||
"name": "GPL-3.0",
|
||||
"url": "https://github.com/Kareadita/Kavita/blob/develop/LICENSE"
|
||||
},
|
||||
"version": "0.7.1.38"
|
||||
"version": "0.7.1.41"
|
||||
},
|
||||
"servers": [
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user