summaryrefslogtreecommitdiff
path: root/js/truncate.ts
diff options
context:
space:
mode:
Diffstat (limited to 'js/truncate.ts')
-rw-r--r--js/truncate.ts5
1 files changed, 1 insertions, 4 deletions
diff --git a/js/truncate.ts b/js/truncate.ts
index c721404a1..0e9a8b977 100644
--- a/js/truncate.ts
+++ b/js/truncate.ts
@@ -10,10 +10,7 @@ function req(
const builder = flatbuffers.createBuilder();
const name_ = builder.createString(name);
len = len && len > 0 ? Math.floor(len) : 0;
- msg.Truncate.startTruncate(builder);
- msg.Truncate.addName(builder, name_);
- msg.Truncate.addLen(builder, len);
- const inner = msg.Truncate.endTruncate(builder);
+ const inner = msg.Truncate.createTruncate(builder, name_, len);
return [builder, msg.Any.Truncate, inner];
}