Add explicit types for public fields

This commit is contained in:
Hugh Nimmo-Smith
2024-11-06 14:13:00 +00:00
parent bcbdb596a3
commit b0e0e0ed6b

View File

@@ -210,7 +210,7 @@ abstract class BaseMediaViewModel extends ViewModel {
/** /**
* Whether the media belongs to the local user. * Whether the media belongs to the local user.
*/ */
public readonly local = this.participant.pipe( public readonly local: Observable<boolean> = this.participant.pipe(
// We can assume, that the user is not local if the participant is undefined // We can assume, that the user is not local if the participant is undefined
// We assume the local LK participant will always be available. // We assume the local LK participant will always be available.
map((p) => p?.isLocal ?? false), map((p) => p?.isLocal ?? false),
@@ -224,9 +224,8 @@ abstract class BaseMediaViewModel extends ViewModel {
*/ */
public readonly unencryptedWarning: Observable<boolean>; public readonly unencryptedWarning: Observable<boolean>;
public readonly isRTCParticipantAvailable = this.participant.pipe( public readonly isRTCParticipantAvailable: Observable<boolean> =
map((p) => !!p), this.participant.pipe(map((p) => !!p));
);
public readonly encryptionStatus: Observable<EncryptionStatus>; public readonly encryptionStatus: Observable<EncryptionStatus>;