public Startup(IConfiguration configuration) { Configuration = configuration; using (var context = new AnimesPlanetDataContext()) { context.Database.Migrate(); } }
public List <Anime> Index() { List <Anime> list = null; using (AnimesPlanetDataContext db = new AnimesPlanetDataContext()) { list = db.Animes.ToList(); } return(list); }