Skip to content

Commit d432c06

Browse files
committed
refactor: flip allowConcurrentAudioPlayback to disabled
1 parent 6efbbd0 commit d432c06

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/components/AudioPlayer/AudioPlayerPool.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export class AudioPlayerPool {
88
private allowConcurrentPlayback: boolean;
99

1010
constructor(config?: { allowConcurrentPlayback?: boolean }) {
11-
this.allowConcurrentPlayback = config?.allowConcurrentPlayback ?? true;
11+
this.allowConcurrentPlayback = !!config?.allowConcurrentPlayback;
1212
}
1313

1414
get players() {

src/components/Channel/Channel.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ type ChannelPropsForwardedToComponentContext = Pick<
168168
export type ChannelProps = ChannelPropsForwardedToComponentContext & {
169169
/** Custom handler function that runs when the active channel has unread messages and the app is running on a separate browser tab */
170170
activeUnreadHandler?: (unread: number, documentTitle: string) => void;
171-
/** Allows a single audio to be played by any audio player at a time. */
171+
/** Allows multiple audio players to play the audio at the same time. Disabled by default. */
172172
allowConcurrentAudioPlayback?: boolean;
173173
/** The connected and active channel */
174174
channel?: StreamChannel;
@@ -291,7 +291,7 @@ const ChannelInner = (
291291
) => {
292292
const {
293293
activeUnreadHandler,
294-
allowConcurrentAudioPlayback = true,
294+
allowConcurrentAudioPlayback,
295295
channel,
296296
channelQueryOptions: propChannelQueryOptions,
297297
children,

0 commit comments

Comments
 (0)