Skip to content

Commit 41ca94a

Browse files
committed
WebExtension
1 parent 0729352 commit 41ca94a

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

dotnet/src/webdriver/BiDi/Communication/Json/BiDiJsonSerializerContext.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,8 @@ namespace OpenQA.Selenium.BiDi.Communication.Json;
203203
[JsonSerializable(typeof(WebExtension.InstallCommand))]
204204
[JsonSerializable(typeof(WebExtension.InstallResult))]
205205
[JsonSerializable(typeof(WebExtension.UninstallCommand))]
206+
[JsonSerializable(typeof(WebExtension.UninstallResult))]
207+
206208
[JsonSerializable(typeof(Emulation.SetTimezoneOverrideCommand))]
207209
[JsonSerializable(typeof(Emulation.SetUserAgentOverrideCommand))]
208210
[JsonSerializable(typeof(Emulation.SetLocaleOverrideCommand))]

dotnet/src/webdriver/BiDi/WebExtension/UninstallCommand.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,10 @@
2222
namespace OpenQA.Selenium.BiDi.WebExtension;
2323

2424
internal sealed class UninstallCommand(UninstallParameters @params)
25-
: Command<UninstallParameters, EmptyResult>(@params, "webExtension.uninstall");
25+
: Command<UninstallParameters, UninstallResult>(@params, "webExtension.uninstall");
2626

2727
internal sealed record UninstallParameters(Extension Extension) : Parameters;
2828

2929
public sealed class UninstallOptions : CommandOptions;
30+
31+
public sealed record UninstallResult : EmptyResult;

dotnet/src/webdriver/BiDi/WebExtension/WebExtensionModule.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ public async Task<InstallResult> InstallAsync(ExtensionData extensionData, Insta
3131
return await Broker.ExecuteCommandAsync(new InstallCommand(@params), options, JsonContext.InstallCommand, JsonContext.InstallResult).ConfigureAwait(false);
3232
}
3333

34-
public async Task<EmptyResult> UninstallAsync(Extension extension, UninstallOptions? options = null)
34+
public async Task<UninstallResult> UninstallAsync(Extension extension, UninstallOptions? options = null)
3535
{
3636
var @params = new UninstallParameters(extension);
3737

38-
return await Broker.ExecuteCommandAsync(new UninstallCommand(@params), options, JsonContext.UninstallCommand, JsonContext.EmptyResult).ConfigureAwait(false);
38+
return await Broker.ExecuteCommandAsync(new UninstallCommand(@params), options, JsonContext.UninstallCommand, JsonContext.UninstallResult).ConfigureAwait(false);
3939
}
4040
}

0 commit comments

Comments
 (0)