Skip to content

Commit eac00e3

Browse files
committed
Limit dialog text length for xAPI tracking to 25 characters
1 parent 3c98e50 commit eac00e3

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/managers/dialogManager.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ export default class DialogManager {
262262
else if (this.currNode.type === "text") {
263263
if(!this.launched) {
264264
var dialog = this.currNode.dialogs[0];
265-
xapiTracker.completable(`${dialog.name} ${dialog.text}`, xapiTracker.COMPLETABLETYPE.STORYNODE)
265+
xapiTracker.completable(`${dialog.name} ${dialog.text.slice(0, 25)}`, xapiTracker.COMPLETABLETYPE.STORYNODE)
266266
.initialized()
267267
.send();
268268
this.launched=true;
@@ -367,7 +367,7 @@ export default class DialogManager {
367367
// Actualiza el ultimo personaje que se ha hablado
368368
this.lastCharacter = this.currNode.character;
369369
var dialog = this.currNode.dialogs[0];
370-
xapiTracker.completable(`${dialog.name} ${dialog.text}`, xapiTracker.COMPLETABLETYPE.STORYNODE)
370+
xapiTracker.completable(`${dialog.name} ${dialog.text.slice(0, 25)}`, xapiTracker.COMPLETABLETYPE.STORYNODE)
371371
.completed(true, true)
372372
.send();
373373
this.launched=false;

0 commit comments

Comments
 (0)