Skip to content

Commit 7ee7724

Browse files
committed
#142 Refactored to use non-deprecated overload
1 parent e12fac5 commit 7ee7724

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

tools/AppHost/Extensions/SqlServerCommandExt.cs

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,18 @@ public static IResourceBuilder<SqlServerDatabaseResource> WithDropDatabaseComman
2323

2424
return CommandResults.Success();
2525
},
26-
context =>
27-
{
28-
if (context.ResourceSnapshot.HealthStatus is HealthStatus.Healthy)
26+
new CommandOptions {
27+
UpdateState = context =>
2928
{
30-
return ResourceCommandState.Enabled;
31-
}
29+
if (context.ResourceSnapshot.HealthStatus is HealthStatus.Healthy)
30+
{
31+
return ResourceCommandState.Enabled;
32+
}
3233

33-
return ResourceCommandState.Disabled;
34+
return ResourceCommandState.Disabled;
35+
}
3436
});
37+
3538
return builder;
3639
}
3740
}

0 commit comments

Comments
 (0)