fix: removed view project buttons from Python cert projects (#54261)

pull/54123/head
Jenna (Ju Hee) Han 2024-04-03 12:16:07 -04:00 committed by GitHub
parent 002212c437
commit 38d84616ee
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 3 deletions

View File

@ -23,7 +23,7 @@ describe('getSolutionDisplayType', () => {
'showMultifileProjectSolution'
);
expect(getSolutionDisplayType(multifilePythonSolution)).toBe(
'showMultifileProjectSolution'
'showUserCode'
);
});
it('should handle solutions with a single valid url', () => {

View File

@ -19,8 +19,7 @@ export const getSolutionDisplayType = ({
}: CompletedChallenge): DisplayType => {
if (examResults) return 'showExamResults';
if (challengeFiles?.length)
return challengeType === challengeTypes.multifileCertProject ||
challengeType === challengeTypes.multifilePythonCertProject
return challengeType === challengeTypes.multifileCertProject
? 'showMultifileProjectSolution'
: 'showUserCode';
if (!solution) return 'none';