Functional

This commit is contained in:
kdeng00
2021-12-23 21:10:13 -05:00
parent 8600d9b6bc
commit edaea68296
33 changed files with 362 additions and 298 deletions
+6 -4
View File
@@ -3,9 +3,6 @@ using System.Collections.Generic;
using System.Linq;
using Microsoft.EntityFrameworkCore;
using MySql.Data;
using MySql.Data.EntityFrameworkCore.Extensions;
using MySql.Data.MySqlClient;
using Icarus.Models;
@@ -27,9 +24,14 @@ namespace Icarus.Database.Contexts
}
public Genre RetrieveRecord(Genre genre)
{
return Genres.FirstOrDefault(gnr => gnr.GenreID == genre.GenreID);
}
public bool DoesRecordExist(Genre genre)
{
return Genres.FirstOrDefault(gnr => gnr.GenreId == genre.GenreId) != null ? true : false;
return Genres.FirstOrDefault(gnr => gnr.GenreID == genre.GenreID) != null ? true : false;
}
}
}