From 18cadc79c143a0ebda178fa4763d0c30617cbd04 Mon Sep 17 00:00:00 2001 From: sssooonnnggg Date: Sat, 13 May 2023 01:49:50 +0800 Subject: fix(TS): fixed incorrect function name when importing unionTo functions (#7958) --- src/idl_gen_ts.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/idl_gen_ts.cpp b/src/idl_gen_ts.cpp index a21b21bd..7bee3f80 100644 --- a/src/idl_gen_ts.cpp +++ b/src/idl_gen_ts.cpp @@ -849,8 +849,8 @@ class TsGenerator : public BaseGenerator { } if (enum_def.is_union) { - symbols_expression += ", unionTo" + name; - symbols_expression += ", unionListTo" + name; + symbols_expression += (", " + namer_.Function("unionTo" + name)); + symbols_expression += (", " + namer_.Function("unionListTo" + name)); } return symbols_expression; -- cgit v1.2.3