Skip to content

Commit 7926ecd

Browse files
committed
fix(octra): can't log out on project lists page
1 parent fadb805 commit 7926ecd

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

apps/octra/src/app/core/store/login-mode/annotation/annotation.effects.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import {
1010
forkJoin,
1111
interval,
1212
map,
13+
Observable,
1314
of,
1415
Subscription,
1516
tap,
@@ -1067,7 +1068,7 @@ export class AnnotationEffects {
10671068
map((a) => {
10681069
return AnnotationActions.sendOnlineAnnotation.success({
10691070
mode: state.application.mode!,
1070-
task: a,
1071+
task: a!,
10711072
});
10721073
}),
10731074
catchError((error: HttpErrorResponse) => {
@@ -1728,7 +1729,14 @@ export class AnnotationEffects {
17281729
}
17291730
}
17301731

1731-
private saveTaskToServer(state: RootState, status: TaskStatus) {
1732+
private saveTaskToServer(
1733+
state: RootState,
1734+
status: TaskStatus
1735+
): Observable<TaskDto | undefined> {
1736+
if (!this.audio.audioManager?.resource) {
1737+
return of(undefined);
1738+
}
1739+
17321740
const result = new AnnotJSONConverter().export(
17331741
state.onlineMode.transcript
17341742
.clone()

0 commit comments

Comments
 (0)