private void DisposeConnection() { try { lock (_disposeLock) { using (WriteLock.Write()) { _connection?.Dispose(); _dbConnection?.Dispose(); } } } catch (Exception ex) { _logger.LogError(ex, "Error disposing database", ex); } }
private void DisposeConnection() { try { lock (_disposeLock) { using (WriteLock.Write()) { _connection?.Dispose(); #if JELLYFIN _dbConnection?.Dispose(); #endif } } } catch (Exception ex) { _logger.LogError(ex, $"Error disposing database: {ex}"); } }