Skip to content

Commit 432bb8f

Browse files
author
Geoffrey Hendrey
committed
strict true
1 parent 6738199 commit 432bb8f

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed
File renamed without changes.

src/TemplateProcessor.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1286,7 +1286,7 @@ export default class TemplateProcessor {
12861286
const {compiledExpr__, exprTargetJsonPointer__, expr__} = metaInfo;
12871287
let target;
12881288
try {
1289-
target = jp.get(output, exprTargetJsonPointer__); //an expression is always relative to a target
1289+
target = jp.get(output, exprTargetJsonPointer__ as JsonPointerString); //an expression is always relative to a target
12901290
const safe = this.withErrorHandling.bind(this);
12911291
const jittedFunctions: { [key: string]: (arg: any) => Promise<any> } = {};
12921292
for (const k of this.functionGenerators.keys()) {
@@ -1316,7 +1316,7 @@ export default class TemplateProcessor {
13161316
...{"set": safe(this.generateSet(planStep))},
13171317
...jittedFunctions
13181318
};
1319-
evaluated = await compiledExpr__.evaluate(
1319+
evaluated = await compiledExpr__?.evaluate(
13201320
target,
13211321
context
13221322
);
@@ -1466,9 +1466,11 @@ export default class TemplateProcessor {
14661466
//a jsonPointer like '/rxLog/-'. Which means "last element of rxLog". queueParent() allows us to
14671467
//pickup the /rxLog array as being an implicit dependency of its array elements. So if an element
14681468
//is added or removed, we will recognize anyone who depends on /rxLog as a dependent
1469+
//@ts-ignore
14691470
if (!jp.has(this.templateMeta, currentPtr)){
14701471
continue;
14711472
}
1473+
//@ts-ignore
14721474
const metaInf = jp.get(this.templateMeta, currentPtr) as MetaInfo;
14731475
if(metaInf.isFunction__){
14741476
continue; //function never gets re-evaluated

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"compilerOptions": {
3-
"strict": false,
3+
"strict": true,
44
"module": "NodeNext",
55
"target": "esnext",
66
"sourceMap": true,

0 commit comments

Comments
 (0)