public async Task SeedAsync(DataSeedContext context) { if (await _companiesRepository.GetCountAsync() > 0) { return; } var orwell = await _companiesRepository.InsertAsync( new Company { Name = "Company 1", CreteadDate = new DateTime(2020, 6, 8) }, autoSave : true ); await _companiesRepository.InsertAsync( new Company { Name = "Company 2", CreteadDate = new DateTime(2019, 9, 27) }, autoSave : true ); await _authorRepository.InsertAsync( await _authorManager.CreateAsync( "Listing 2", new DateTime(1952, 03, 11), orwell.Id, "Listing desc" ) ); }