ADD error handling
This commit is contained in:
@@ -2,6 +2,7 @@ package com.ddf.vodsystem.services;
|
||||
|
||||
import com.ddf.vodsystem.entities.ClipConfig;
|
||||
import com.ddf.vodsystem.entities.Job;
|
||||
import com.ddf.vodsystem.entities.JobStatus;
|
||||
import com.ddf.vodsystem.exceptions.JobNotFound;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@@ -36,6 +37,10 @@ public class EditService {
|
||||
throw new JobNotFound(uuid);
|
||||
}
|
||||
|
||||
if (job.getStatus() == JobStatus.FINISHED) {
|
||||
return 1f;
|
||||
}
|
||||
|
||||
return job.getProgress();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user