aboutsummaryrefslogtreecommitdiff
path: root/src/DevHive.Data/Repositories/LanguageRepository.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/DevHive.Data/Repositories/LanguageRepository.cs')
-rw-r--r--src/DevHive.Data/Repositories/LanguageRepository.cs8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/DevHive.Data/Repositories/LanguageRepository.cs b/src/DevHive.Data/Repositories/LanguageRepository.cs
index 808fa9a..59c88a6 100644
--- a/src/DevHive.Data/Repositories/LanguageRepository.cs
+++ b/src/DevHive.Data/Repositories/LanguageRepository.cs
@@ -17,7 +17,6 @@ namespace DevHive.Data.Repositories
}
#region Create
-
public async Task<bool> AddAsync(Language entity)
{
await this._context.Languages
@@ -28,7 +27,6 @@ namespace DevHive.Data.Repositories
#endregion
#region Read
-
public async Task<Language> GetByIdAsync(Guid id)
{
return await this._context.Languages
@@ -58,19 +56,15 @@ namespace DevHive.Data.Repositories
#endregion
#region Delete
-
public async Task<bool> DeleteAsync(Language entity)
{
- this._context
- .Set<Language>()
- .Remove(entity);
+ this._context.Languages.Remove(entity);
return await this.SaveChangesAsync(this._context);
}
#endregion
#region Validations
-
public async Task<bool> DoesLanguageNameExistAsync(string languageName)
{
return await this._context.Languages