client: refactor Events, Info, RegistryLogin

Co-authored-by: Claude <noreply@anthropic.com>
Signed-off-by: Austin Vazquez <austin.vazquez@docker.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Austin Vazquez
2025-10-20 15:11:53 -05:00
committed by Sebastiaan van Stijn
parent c438b3fbbf
commit e46058cbae
32 changed files with 181 additions and 77 deletions

View File

@@ -70,9 +70,9 @@ func CheckGoroutineCount(ctx context.Context, apiClient client.SystemAPIClient,
}
func getGoroutineNumber(ctx context.Context, apiClient client.SystemAPIClient) (int, error) {
info, err := apiClient.Info(ctx)
result, err := apiClient.Info(ctx, client.InfoOptions{})
if err != nil {
return 0, err
}
return info.NGoroutines, nil
return result.Info.NGoroutines, nil
}