Skip to content

Commit 14ef9c0

Browse files
authored
chore: added error message for capturing error (#561)
1 parent abe91b9 commit 14ef9c0

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

video/src/main/java/beta/video/StreamingShotChangeDetection.java

+5-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,11 @@ static void streamingShotChangeDetection(String filePath)
8484

8585
for (StreamingAnnotateVideoResponse response : call) {
8686
StreamingVideoAnnotationResults annotationResults = response.getAnnotationResults();
87-
87+
if (response.hasError()) {
88+
System.out.println(response.getError().getMessage());
89+
System.out.format("Error was occured with the following status: %s\n",
90+
response.getError());
91+
}
8892
for (VideoSegment segment : annotationResults.getShotAnnotationsList()) {
8993
double startTimeOffset =
9094
segment.getStartTimeOffset().getSeconds()

0 commit comments

Comments
 (0)