@@ -61,7 +61,7 @@ export const mapColumn: ExpressionFunctionDefinition<
6161 aliases : [ 'exp' , 'fn' , 'function' ] ,
6262 help : i18n . translate ( 'expressions.functions.mapColumn.args.expressionHelpText' , {
6363 defaultMessage :
64- 'A {CANVAS} expression that is passed to each row as a single row {DATATABLE}.' ,
64+ 'An expression that is executed on every row, provided with a single- row {DATATABLE} context and returning the cell value .' ,
6565 values : {
6666 CANVAS : 'canvas' ,
6767 DATATABLE : '`datatable`' ,
@@ -73,7 +73,7 @@ export const mapColumn: ExpressionFunctionDefinition<
7373 types : [ 'string' , 'null' ] ,
7474 help : i18n . translate ( 'expressions.functions.mapColumn.args.copyMetaFromHelpText' , {
7575 defaultMessage :
76- "If set, the meta object from the specified column id is copied over to the specified target column. Throws an exception if the column doesn't exist" ,
76+ "If set, the meta object from the specified column id is copied over to the specified target column. If the column doesn't exist it silently fails. " ,
7777 } ) ,
7878 required : false ,
7979 default : null ,
@@ -104,7 +104,7 @@ export const mapColumn: ExpressionFunctionDefinition<
104104 meta : { type } ,
105105 } ;
106106 if ( args . copyMetaFrom ) {
107- const metaSourceFrom = columns . find ( ( { name } ) => name === args . copyMetaFrom ) ;
107+ const metaSourceFrom = columns . find ( ( { id } ) => id === args . copyMetaFrom ) ;
108108 newColumn . meta = { ...newColumn . meta , ...( metaSourceFrom ?. meta || { } ) } ;
109109 }
110110
0 commit comments