Skip to content

Commit 4b7b94a

Browse files
committed
Minor changes
1 parent d56bf4a commit 4b7b94a

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

MsSql.ClassGenerator/Ui/ViewModel/MainWindowViewModel.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -412,9 +412,7 @@ private async Task SelectAsync()
412412
await _tableManager.LoadTablesAsync();
413413

414414
// Set the tables
415-
_originTables = _tableManager.Tables
416-
.Select(s => new TableColumnDto(s))
417-
.OrderBy(o => o.Name).ToList();
415+
_originTables = [.._tableManager.Tables.Select(s => new TableColumnDto(s)).OrderBy(o => o.Name)];
418416

419417
FilterTables();
420418

@@ -488,7 +486,7 @@ private async Task EditConnectionAsync()
488486
try
489487
{
490488
// Update the server list
491-
await SettingsManager.SaveServerListAsync(ServerList.ToList());
489+
await SettingsManager.SaveServerListAsync([..ServerList]);
492490
}
493491
catch (Exception ex)
494492
{

0 commit comments

Comments
 (0)