fix CSV and XLS export when no parent