Skip to content

Commit 1325638

Browse files
committed
refactoring
1 parent 3940667 commit 1325638

File tree

4 files changed

+2
-8
lines changed

4 files changed

+2
-8
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ A simple helper to perform async application initialization for the generic host
6161
6262
You can also pass a `CancellationToken` in order to propagate notifications to cancel the initialization if needed.
6363
64-
In the following example, the initialization will be cancelled:
64+
In the following example, the initialization will be cancelled when `Ctrl + C` keys are pressed :
6565
```csharp
6666
public static async Task Main(string[] args)
6767
{

src/Extensions.Hosting.AsyncInitialization/DependencyInjection/AsyncInitializationServiceCollectionExtensions.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,11 +131,6 @@ public DelegateAsyncInitializer(Func<CancellationToken, Task> initializer)
131131
_initializer = initializer;
132132
}
133133

134-
135-
///<inheritdoc/>
136-
public Task InitializeAsync() => InitializeAsync(CancellationToken.None);
137-
138-
///<inheritdoc/>
139134
public Task InitializeAsync(CancellationToken cancellationToken)
140135
{
141136
return _initializer(cancellationToken);

src/Extensions.Hosting.AsyncInitialization/Extensions.Hosting.AsyncInitialization.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020

2121
<ItemGroup>
2222
<PackageReference Include="Microsoft.Extensions.Hosting.Abstractions" Version="2.1.0" />
23-
<PackageReference Include="Microsoft.AspNetCore.Hosting" Version="2.1.0" />
2423
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="2.1.0" />
2524
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="2.1.0" />
2625
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0" PrivateAssets="All" />

src/Extensions.Hosting.AsyncInitialization/IAsyncInitializer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ namespace Extensions.Hosting.AsyncInitialization
99
public interface IAsyncInitializer
1010
{
1111
/// <summary>
12-
/// Performs async initialization
12+
/// Performs async initialization.
1313
/// </summary>
1414
/// <param name="cancellationToken">Notifies that the operation should be cancelled</param>
1515
/// <returns>A task that represents the initialization completion.</returns>

0 commit comments

Comments
 (0)