From 5d1613db8e8e30ce7cadf44317b9b2e4036ecad8 Mon Sep 17 00:00:00 2001 From: Ben Clayton Date: Tue, 28 Sep 2021 18:08:13 +0000 Subject: [PATCH] dawn_node: Fix Converter>::FromJS The conversion should only pass if the element type matches. Bug: dawn:1123 Change-Id: I700a445e8d281afdc36d1b6f9be73767ca89d4ea Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/65240 Commit-Queue: Ben Clayton Reviewed-by: Antonio Maiorano Reviewed-by: Austin Eng --- src/dawn_node/interop/Core.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dawn_node/interop/Core.h b/src/dawn_node/interop/Core.h index 1ad3bb9bee..4460f9fdde 100644 --- a/src/dawn_node/interop/Core.h +++ b/src/dawn_node/interop/Core.h @@ -279,8 +279,8 @@ namespace wgpu { namespace interop { auto arr = value.As>(); if (arr.TypedArrayType() == element_type) { out = arr; + return true; } - return true; } return false; };