fix(radarr): invoke reset on processors when doing preview

This caused logs to be duplicated
recyclarr
Robert Dailey 4 years ago
parent 46675e38c5
commit df993016d7

@ -14,6 +14,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
custom formats in the guide have the same name (e.g. 'DoVi').
- Debug-level logs are now written to file in addition to the Info-level logs in console output.
### Fixed
- An issue with radarr `--preview` that caused duplicate output when updating a second instance has
been fixed.
## [1.4.2] - 2021-05-15
### Fixed

@ -43,18 +43,19 @@ namespace Trash.Radarr.CustomFormat
if (args.Preview)
{
PreviewCustomFormats();
return;
}
else
{
await _persistenceProcessor.PersistCustomFormats(_guideProcessor.ProcessedCustomFormats,
_guideProcessor.DeletedCustomFormatsInCache, _guideProcessor.ProfileScores);
await _persistenceProcessor.PersistCustomFormats(_guideProcessor.ProcessedCustomFormats,
_guideProcessor.DeletedCustomFormatsInCache, _guideProcessor.ProfileScores);
PrintApiStatistics(args, _persistenceProcessor.Transactions);
PrintQualityProfileUpdates();
PrintApiStatistics(args, _persistenceProcessor.Transactions);
PrintQualityProfileUpdates();
// Cache all the custom formats (using ID from API response).
_cache.Update(_guideProcessor.ProcessedCustomFormats);
_cache.Save();
// Cache all the custom formats (using ID from API response).
_cache.Update(_guideProcessor.ProcessedCustomFormats);
_cache.Save();
}
_persistenceProcessor.Reset();
_guideProcessor.Reset();

Loading…
Cancel
Save