diff options
| author | transtrike <transtrike@gmail.com> | 2021-01-19 20:36:39 +0200 |
|---|---|---|
| committer | transtrike <transtrike@gmail.com> | 2021-01-19 20:36:39 +0200 |
| commit | 33b5f6297c2c975bec8a74a8facc208261c03c9e (patch) | |
| tree | 20593ba74065681cd86ce852a65f3efc1dc0036b /src/DevHive.Data/Repositories/RoleRepository.cs | |
| parent | c96a880768d8dee9449aa4f69e14bddc8e0d92f9 (diff) | |
| download | DevHive-33b5f6297c2c975bec8a74a8facc208261c03c9e.tar DevHive-33b5f6297c2c975bec8a74a8facc208261c03c9e.tar.gz DevHive-33b5f6297c2c975bec8a74a8facc208261c03c9e.zip | |
Replaced RepoMethods with BaseClass and inherited it where needed
Diffstat (limited to 'src/DevHive.Data/Repositories/RoleRepository.cs')
| -rw-r--r-- | src/DevHive.Data/Repositories/RoleRepository.cs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/DevHive.Data/Repositories/RoleRepository.cs b/src/DevHive.Data/Repositories/RoleRepository.cs index ca3fb8b..684fbd7 100644 --- a/src/DevHive.Data/Repositories/RoleRepository.cs +++ b/src/DevHive.Data/Repositories/RoleRepository.cs @@ -7,7 +7,7 @@ using Microsoft.EntityFrameworkCore; namespace DevHive.Data.Repositories { - public class RoleRepository : IRoleRepository + public class RoleRepository : BaseRepository, IRoleRepository { private readonly DevHiveContext _context; @@ -23,7 +23,7 @@ namespace DevHive.Data.Repositories .Set<Role>() .AddAsync(entity); - return await RepositoryMethods.SaveChangesAsync(this._context); + return await this.SaveChangesAsync(this._context); } //Read @@ -51,7 +51,7 @@ namespace DevHive.Data.Repositories .CurrentValues .SetValues(newEntity); - return await RepositoryMethods.SaveChangesAsync(this._context); + return await this.SaveChangesAsync(this._context); } //Delete @@ -61,7 +61,7 @@ namespace DevHive.Data.Repositories .Set<Role>() .Remove(entity); - return await RepositoryMethods.SaveChangesAsync(this._context); + return await this.SaveChangesAsync(this._context); } public async Task<bool> DoesNameExist(string name) |
