Skip to content

Commit

Permalink
Addressed the PR review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
rmanaem committed Dec 13, 2024
1 parent e892caf commit c6d45fd
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
12 changes: 6 additions & 6 deletions cypress/e2e/ResultsTSV.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,8 @@ describe('Unprotected response', () => {
expect(phenotypicSession.split('\t')[12]).to.equal('multisource interference task');
expect(phenotypicSession.split('\t')[13]).to.equal('');
expect(phenotypicSession.split('\t')[14]).to.equal('');
expect(phenotypicSession.split('\t')[15]).to.equal('Flow Weighted, T2 Weighted');
expect(phenotypicSession.split('\t')[16]).to.equal('fmriprep 23.1.3, freesurfer 7.3.2');
expect(phenotypicSession.split('\t')[15]).to.equal('Flow Weighted,T2 Weighted');
expect(phenotypicSession.split('\t')[16]).to.equal('fmriprep 23.1.3,freesurfer 7.3.2');

expect(imagingSession.split('\t')[0]).to.equal('some dataset');
expect(imagingSession.split('\t')[1]).to.equal(
Expand All @@ -133,10 +133,10 @@ describe('Unprotected response', () => {
expect(imagingSession.split('\t')[10]).to.equal('');
expect(imagingSession.split('\t')[11]).to.equal('');
expect(imagingSession.split('\t')[12]).to.equal('');
expect(imagingSession.split('\t')[13]).to.equal('Flow Weighted, T2 Weighted');
expect(imagingSession.split('\t')[14]).to.equal('fmriprep 23.1.3, freesurfer 7.3.2');
expect(imagingSession.split('\t')[15]).to.equal('Flow Weighted, T2 Weighted');
expect(imagingSession.split('\t')[16]).to.equal('fmriprep 23.1.3, freesurfer 7.3.2');
expect(imagingSession.split('\t')[13]).to.equal('Flow Weighted,T2 Weighted');
expect(imagingSession.split('\t')[14]).to.equal('fmriprep 23.1.3,freesurfer 7.3.2');
expect(imagingSession.split('\t')[15]).to.equal('Flow Weighted,T2 Weighted');
expect(imagingSession.split('\t')[16]).to.equal('fmriprep 23.1.3,freesurfer 7.3.2');
});
});
});
16 changes: 8 additions & 8 deletions src/components/ResultContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ function ResultContainer({
): string | string[] | null {
// Handle array of URIs
if (Array.isArray(uri)) {
return uri.map((singleUri) => convertURIToLabel(type, singleUri)).join(', ');
return uri.map((singleUri) => convertURIToLabel(type, singleUri)).join(',');
}

if (!uri) {
Expand Down Expand Up @@ -136,7 +136,7 @@ function ResultContainer({
.flatMap(([name, versions]) =>
(versions as string[]).map((version: string) => `${name} ${version}`)
)
.join(', ')
.join(',')
: '';
}

Expand Down Expand Up @@ -187,11 +187,11 @@ function ResultContainer({
'protected', // session_completed_pipelines
isHumanFile
? convertURIToLabel('modality', res.image_modals)
: res.image_modals?.join(', '),
: res.image_modals?.join(','),
isHumanFile
? convertURIToLabel(
'pipeline',
parsePipelinesInfoToString(res.available_pipelines).split(', ')
parsePipelinesInfoToString(res.available_pipelines).split(',')
)
: parsePipelinesInfoToString(res.available_pipelines),
].join('\t')
Expand Down Expand Up @@ -220,20 +220,20 @@ function ResultContainer({
: subject.assessment,
isHumanFile
? convertURIToLabel('modality', subject.image_modal)
: subject.image_modal?.join(', '),
: subject.image_modal?.join(','),
isHumanFile
? convertURIToLabel(
'pipeline',
parsePipelinesInfoToString(subject.completed_pipelines).split(', ')
parsePipelinesInfoToString(subject.completed_pipelines).split(',')
)
: parsePipelinesInfoToString(subject.completed_pipelines),
isHumanFile
? convertURIToLabel('modality', res.image_modals)
: res.image_modals?.join(', '),
: res.image_modals?.join(','),
isHumanFile
? convertURIToLabel(
'pipeline',
parsePipelinesInfoToString(res.available_pipelines).split(', ')
parsePipelinesInfoToString(res.available_pipelines).split(',')
)
: parsePipelinesInfoToString(res.available_pipelines),
].join('\t')
Expand Down

0 comments on commit c6d45fd

Please sign in to comment.