Skip to content

Commit

Permalink
DATAAPI-34 if a custom renderer returns a complex value, just
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
DominicWatson committed Oct 30, 2024
1 parent f721b33 commit 740d735
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion services/DataApiService.cfc
Original file line number Diff line number Diff line change
Expand Up @@ -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 ) {
Expand Down

0 comments on commit 740d735

Please sign in to comment.