File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1052,14 +1052,19 @@ function useSearchBulkActions({queryJSON}: UseSearchBulkActionsParams) {
10521052 return exportOptions ;
10531053 } ;
10541054
1055+ const subMenuItems = getExportOptions ( ) ;
1056+ if ( subMenuItems . length === 1 ) {
1057+ return subMenuItems ;
1058+ }
1059+
10551060 const exportButtonOption : DropdownOption < SearchHeaderOptionValue > & Pick < PopoverMenuItem , 'rightIcon' > = {
10561061 icon : expensifyIcons . Export ,
10571062 rightIcon : expensifyIcons . ArrowRight ,
10581063 text : translate ( 'common.export' ) ,
10591064 backButtonText : translate ( 'common.export' ) ,
10601065 value : CONST . SEARCH . BULK_ACTION_TYPES . EXPORT ,
10611066 shouldCloseModalOnSelect : true ,
1062- subMenuItems : getExportOptions ( ) ,
1067+ subMenuItems : subMenuItems ,
10631068 } ;
10641069
10651070 if ( areAllMatchingItemsSelected ) {
You can’t perform that action at this time.
0 commit comments