mirror of
https://github.com/lightpanda-io/browser.git
synced 2025-10-29 23:23:28 +00:00
Fix non-probing of union array failure
Probing a union match for an possible value should rarely hard-fail. Instead,
it should return an .{.invalid = {}} response to let the prober decide how to
proceed. This fixes a hard-fail when a JS value fails to probe as an array.
Also, add :modal pseudo-class.
(both issues came up looking at github integration)
This commit is contained in:
@@ -1158,7 +1158,7 @@ pub fn Env(comptime State: type, comptime WebApis: type) type {
|
||||
}
|
||||
|
||||
if (!js_value.isArray()) {
|
||||
return error.InvalidArgument;
|
||||
return .{.invalid = {}};
|
||||
}
|
||||
|
||||
// This can get tricky.
|
||||
|
||||
Reference in New Issue
Block a user