Skip to content

Commit 6e13459

Browse files
committed
refactor(models): replace magic value , by const for better understanding
1 parent 6fb4520 commit 6e13459

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/models/Script.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,14 @@ export class Script {
1616
bias: number | undefined;
1717

1818
constructor({ script, parameters, builtIn }: ScriptArguments) {
19+
const TAGS_SEPARATOR = ',';
20+
1921
this.scriptCode = script;
2022
this.isBuiltInt = builtIn;
2123

2224
this.name = parameters['name'] as string;
2325
this.desc = parameters['description'] as string;
24-
this.tags = (parameters['tags'] as string).split(',');
26+
this.tags = (parameters['tags'] as string).split(TAGS_SEPARATOR);
2527
this.bias = parameters['bias'] as number;
2628
}
2729
}

0 commit comments

Comments
 (0)