From f721b33f668dfe2ce4201536f4df3d535dacd3ee Mon Sep 17 00:00:00 2001 From: Dominic Watson Date: Wed, 30 Oct 2024 14:27:09 +0000 Subject: [PATCH 1/2] [twgit] Init feature 'feature-DATAAPI-34_rendering-empty-non-simple-values'. From 740d735e01007fe87d690148cc269e366603f923 Mon Sep 17 00:00:00 2001 From: Dominic Watson Date: Wed, 30 Oct 2024 14:27:22 +0000 Subject: [PATCH 2/2] DATAAPI-34 if a custom renderer returns a complex value, just respect it and use it as the render - regardless of whether or not it has length. i.e. we want [] instead of "" returned if that is what the renderer wants. --- services/DataApiService.cfc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/DataApiService.cfc b/services/DataApiService.cfc index 908d5eb..219cf59 100644 --- a/services/DataApiService.cfc +++ b/services/DataApiService.cfc @@ -343,7 +343,7 @@ component { if ( $getContentRendererService().rendererExists( renderer, "dataapi" ) ) { try { var renderedContent = $renderContent( renderer, arguments.value, "dataapi", arguments.fieldSettings ); - if ( Len( renderedContent ?: "" ) ) { + if ( !IsSimpleValue( renderedContent ) || Len( renderedContent ?: "" ) ) { return renderedContent; } } catch( any e ) {