@@ -50,50 +50,50 @@ export const buildPartialUpdateAccountStateCommand = (
5050 } ;
5151
5252 if ( eventName === EventsEnum . IPV_ACCOUNT_INTERVENTION_END ) {
53- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#RIdA' ] = 'reprovedIdentityAt' ;
54- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':rida' ] = { N : String ( eventTimestamp ) } ;
55- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#H' ] = 'history' ;
56- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':h' ] = {
53+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#RIdA' ] = 'reprovedIdentityAt' ;
54+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':rida' ] = { N : String ( eventTimestamp ) } ;
55+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#H' ] = 'history' ;
56+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':h' ] = {
5757 L : extractValidHistoryItems ( historyList , currentTimestamp ) ,
5858 } ;
59- baseUpdateItemCommandInput [ ' UpdateExpression' ] += ', #RIdA = :rida, #H = :h' ;
59+ baseUpdateItemCommandInput . UpdateExpression += ', #RIdA = :rida, #H = :h' ;
6060 return baseUpdateItemCommandInput ;
6161 }
6262
6363 if (
6464 eventName === EventsEnum . AUTH_PASSWORD_RESET_SUCCESSFUL ||
6565 eventName === EventsEnum . AUTH_PASSWORD_RESET_SUCCESSFUL_FOR_TEST_CLIENT
6666 ) {
67- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#RPswdA' ] = 'resetPasswordAt' ;
68- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':rpswda' ] = { N : String ( eventTimestamp ) } ;
69- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#H' ] = 'history' ;
70- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':h' ] = {
67+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#RPswdA' ] = 'resetPasswordAt' ;
68+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':rpswda' ] = { N : String ( eventTimestamp ) } ;
69+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#H' ] = 'history' ;
70+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':h' ] = {
7171 L : extractValidHistoryItems ( historyList , currentTimestamp ) ,
7272 } ;
73- baseUpdateItemCommandInput [ ' UpdateExpression' ] += ', #RPswdA = :rpswda, #H = :h' ;
73+ baseUpdateItemCommandInput . UpdateExpression += ', #RPswdA = :rpswda, #H = :h' ;
7474 return baseUpdateItemCommandInput ;
7575 }
7676
7777 if ( ! interventionName ) {
7878 addMetric ( MetricNames . INTERVENTION_DID_NOT_HAVE_NAME_IN_CURRENT_CONFIG ) ;
7979 throw new Error ( 'The intervention received did not have an interventionName field.' ) ;
8080 }
81- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#INT' ] = 'intervention' ;
82- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':int' ] = { S : interventionName } ;
83- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#AA' ] = 'appliedAt' ;
84- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':aa' ] = { N : String ( currentTimestamp ) } ;
85- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#SA' ] = 'sentAt' ;
86- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':sa' ] = { N : String ( eventTimestamp ) } ;
81+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#INT' ] = 'intervention' ;
82+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':int' ] = { S : interventionName } ;
83+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#AA' ] = 'appliedAt' ;
84+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':aa' ] = { N : String ( currentTimestamp ) } ;
85+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#SA' ] = 'sentAt' ;
86+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':sa' ] = { N : String ( eventTimestamp ) } ;
8787 const stringBuilder = new HistoryStringBuilder ( ) ;
88- baseUpdateItemCommandInput [ ' ExpressionAttributeNames' ] [ '#H' ] = 'history' ;
89- baseUpdateItemCommandInput [ ' ExpressionAttributeValues' ] [ ':h' ] = {
88+ baseUpdateItemCommandInput . ExpressionAttributeNames [ '#H' ] = 'history' ;
89+ baseUpdateItemCommandInput . ExpressionAttributeValues [ ':h' ] = {
9090 L : [
9191 ...extractValidHistoryItems ( historyList , currentTimestamp ) ,
9292 { S : stringBuilder . getHistoryString ( interventionEvent , eventTimestamp ) } ,
9393 ] ,
9494 } ;
95- baseUpdateItemCommandInput [ ' UpdateExpression' ] += ', #INT = :int, #SA = :sa, #AA = :aa, #H = :h' ;
96- baseUpdateItemCommandInput [ ' UpdateExpression' ] += buildRemoveExpression ( finalState ) ;
95+ baseUpdateItemCommandInput . UpdateExpression += ', #INT = :int, #SA = :sa, #AA = :aa, #H = :h' ;
96+ baseUpdateItemCommandInput . UpdateExpression += buildRemoveExpression ( finalState ) ;
9797
9898 return baseUpdateItemCommandInput ;
9999} ;
0 commit comments