mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 10:36:54 -07:00
small tweaks
This commit is contained in:
parent
0fa4005113
commit
e3094d2df1
4 changed files with 2 additions and 40 deletions
|
@ -3,7 +3,7 @@ using System.Threading.Tasks;
|
|||
|
||||
namespace Ombi.Core.Settings
|
||||
{
|
||||
public interface ISettingsService<T> : IDisposable
|
||||
public interface ISettingsService<T>
|
||||
{
|
||||
T GetSettings();
|
||||
Task<T> GetSettingsAsync();
|
||||
|
|
|
@ -155,24 +155,5 @@ namespace Ombi.Settings.Settings
|
|||
return settings.Content;
|
||||
//return _protector.Unprotect(settings.Content);
|
||||
}
|
||||
|
||||
private bool _disposed;
|
||||
protected virtual void Dispose(bool disposing)
|
||||
{
|
||||
if (_disposed)
|
||||
return;
|
||||
|
||||
if (disposing)
|
||||
{
|
||||
Repo?.Dispose();
|
||||
}
|
||||
_disposed = true;
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
Dispose(true);
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -5,7 +5,7 @@ using Ombi.Store.Entities;
|
|||
|
||||
namespace Ombi.Store.Repository
|
||||
{
|
||||
public interface ISettingsRepository : IDisposable
|
||||
public interface ISettingsRepository
|
||||
{
|
||||
/// <summary>
|
||||
/// Inserts the specified entity.
|
||||
|
|
|
@ -121,24 +121,5 @@ namespace Ombi.Store.Repository
|
|||
return r;
|
||||
}
|
||||
}
|
||||
|
||||
private bool _disposed;
|
||||
protected virtual void Dispose(bool disposing)
|
||||
{
|
||||
if (_disposed)
|
||||
return;
|
||||
|
||||
if (disposing)
|
||||
{
|
||||
Db?.Dispose();
|
||||
}
|
||||
_disposed = true;
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
Dispose(true);
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue