We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 403ae95 commit d1e0f95Copy full SHA for d1e0f95
1 file changed
Sources/JavaScriptFoundationCompat/Data+JSValue.swift
@@ -22,7 +22,7 @@ extension Data: ConvertibleToJSValue, ConstructibleFromJSValue {
22
public var jsValue: JSValue { jsTypedArray.jsValue }
23
24
/// Construct a Data from a JSTypedArray<UInt8>.
25
- public static func construct(from uint8Array: JSTypedArray<UInt8>) -> Data? {
+ public static func construct(from uint8Array: JSTypedArray<UInt8>) -> Data {
26
// First, allocate the data storage
27
var data = Data(count: uint8Array.lengthInBytes)
28
// Then, copy the byte contents into the Data buffer
0 commit comments