@@ -5,18 +5,18 @@ import jsonPatcher = require('./common/jsonPatcher');
55import json5Patcher = require( './json5Patcher' ) ;
66import { Operation } from 'fast-json-patch' ;
77
8- var targetPath = tl . getPathInput ( 'JsonWorkingDir' , true ) ;
9- var patchContent = tl . getInput ( 'JsonPatchContent' , true ) ;
8+ try {
9+ var targetPath = tl . getPathInput ( 'JsonWorkingDir' , true ) ;
10+ var patchContent = tl . getInput ( 'JsonPatchContent' , true ) ;
1011
11- var patterns : any = tl . getInput ( 'JsonTargetFilters' , true ) ;
12- var outputPatchedFile = tl . getBoolInput ( 'OutputPatchFile' , true ) ;
13- var failIfNoPatchApplied = tl . getBoolInput ( 'FailIfNoPatchApplied' , true ) ;
14- var treatErrors = tl . getInput ( 'TreatErrors' , true ) ;
15- var syntax = tl . getInput ( 'SyntaxType' , true ) ;
16- var useJson5 = tl . getBoolInput ( 'UseJson5' , true ) ;
17- var produceJson5 = tl . getBoolInput ( 'ProduceJson5' , true ) ;
12+ var patterns : any = tl . getInput ( 'JsonTargetFilters' , true ) ;
13+ var outputPatchedFile = tl . getBoolInput ( 'OutputPatchFile' , true ) ;
14+ var failIfNoPatchApplied = tl . getBoolInput ( 'FailIfNoPatchApplied' , true ) ;
15+ var treatErrors = tl . getInput ( 'TreatErrors' , true ) ;
16+ var syntax = tl . getInput ( 'SyntaxType' , true ) ;
17+ var useJson5 = tl . getBoolInput ( 'UseJson5' , true ) ;
18+ var produceJson5 = tl . getBoolInput ( 'ProduceJson5' , true ) ;
1819
19- try {
2020 var patches : Operation [ ] =
2121 syntax == 'slick'
2222 ? patchProcess . expandVariablesAndParseSlickPatch ( patchContent )
0 commit comments