mirror of
https://github.com/jellyfin/jellyfin-plugin-bookshelf.git
synced 2024-11-30 17:10:25 +00:00
add EmbyTV error handling
This commit is contained in:
parent
944d06bdc4
commit
85c097a19f
@ -493,7 +493,7 @@
|
||||
});
|
||||
});
|
||||
}
|
||||
$('.EmbyTvConfigurationPage').on('pageshow', function (event) { fillFormData(this); });
|
||||
$('.EmbyTvConfigurationPage').on('pageshowready', function (event) { fillFormData(this); });
|
||||
|
||||
$(".schedulesDirectLoginForm").off('submit').on('submit', function (e) {
|
||||
|
||||
|
@ -256,12 +256,9 @@ namespace EmbyTV
|
||||
await host.GetDeviceInfo(cancellationToken);
|
||||
host.Enabled = true;
|
||||
}
|
||||
catch (HttpException)
|
||||
{
|
||||
host.Enabled = false;
|
||||
}
|
||||
catch (ApplicationException)
|
||||
catch (Exception exception)
|
||||
{
|
||||
_logger.ErrorException("Error ensuring connection", exception);
|
||||
host.Enabled = false;
|
||||
}
|
||||
}
|
||||
@ -334,8 +331,15 @@ namespace EmbyTV
|
||||
_tunerServer = TunerHostFactory.CreateTunerHosts(config.TunerHostsConfiguration, _logger, _jsonSerializer, _httpClient);
|
||||
for (var i = 0; i < _tunerServer.Count(); i++)
|
||||
{
|
||||
await _tunerServer[i].GetDeviceInfo(cancellationToken);
|
||||
config.TunerHostsConfiguration[i].ServerId = _tunerServer[i].HostId;
|
||||
try
|
||||
{
|
||||
await _tunerServer[i].GetDeviceInfo(cancellationToken);
|
||||
config.TunerHostsConfiguration[i].ServerId = _tunerServer[i].HostId;
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
_logger.ErrorException("Error getting device info", exception);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -609,8 +613,8 @@ namespace EmbyTV
|
||||
|
||||
public Task UpdateSeriesTimerAsync(SeriesTimerInfo info, CancellationToken cancellationToken)
|
||||
{
|
||||
UpdateTimersForSeriesTimer(info);
|
||||
_seriesTimerProvider.Update(info);
|
||||
UpdateTimersForSeriesTimer(info);
|
||||
return Task.FromResult(true);
|
||||
}
|
||||
|
||||
|
@ -80,7 +80,7 @@ namespace EmbyTV
|
||||
{
|
||||
var list = GetAll().ToList();
|
||||
|
||||
if (list.Any(i => !EqualityComparer(i, item)))
|
||||
if (!list.Any(i => EqualityComparer(i, item)))
|
||||
{
|
||||
Add(item);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user