Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
noahmay committed Mar 12, 2024
1 parent 42fd816 commit 118a1f6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/browser/modules/Stream/CypherFrame/CypherFrame.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -427,10 +427,10 @@ export class CypherFrame extends Component<CypherFrameProps, CypherFrameState> {
const firstRecord = records[0]
const keys = firstRecord?.length > 0 ? firstRecord.keys : []

const exportData = stringifyResultArray(csvFormat, [
keys,
...(records.map(record => recordToStringArray(record)) as any)
])
const exportData = stringifyResultArray(
csvFormat,
[keys].concat(records.map(record => recordToStringArray(record)))
)
const data = exportData.slice()
const csv = CSVSerializer(data.shift())
csv.appendRows(data)
Expand Down

0 comments on commit 118a1f6

Please sign in to comment.