Skip to content
Snippets Groups Projects

Add missing header status code (linked to backend issue #19)

Closed joel.vonderwe requested to merge jw_issue_timeout into main
10 files
+ 85
72
Compare changes
  • Side-by-side
  • Inline
Files
10
@@ -8,15 +8,14 @@ import Json5FileValidator from '../Json5FileValidator';
class SharedAssignmentHelper {
validateDescriptionFile(filePathOrStr: string, isFile: boolean = true, version: number = 1): { content: AssignmentFile | undefined, isValid: boolean, error: string | null } {
switch ( version ) {
case 1:
return Json5FileValidator.validateFile(AssignmentFile, filePathOrStr, isFile);
default:
return {
content: undefined,
isValid: false,
error : `Version ${ version } not supported`
};
if ( version === 1 ) {
return Json5FileValidator.validateFile(AssignmentFile, filePathOrStr, isFile);
} else {
return {
content: undefined,
isValid: false,
error : `Version ${ version } not supported`
};
}
}
@@ -24,7 +23,7 @@ class SharedAssignmentHelper {
const pipelines = await SharedGitlabManager.getRepositoryPipelines(repositoryId, 'main');
if ( pipelines.length > 0 ) {
const lastPipeline = pipelines[0];
if ( lastPipeline.status != GitlabPipelineStatus.SUCCESS ) {
if ( lastPipeline.status !== GitlabPipelineStatus.SUCCESS ) {
return {
isPublishable: false,
lastPipeline : lastPipeline,
Loading