Only update selected if different from current
This commit is contained in:
@@ -64,10 +64,12 @@ export class App extends React.Component<AppProps, AppState> {
|
||||
}
|
||||
|
||||
updateSelect(selected: string): void {
|
||||
if (selected !== this.state.selectedStream) {
|
||||
this.setState((state) => {
|
||||
return { streamList: state.streamList, selectedStream: selected }
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
render() {
|
||||
return (
|
||||
|
Reference in New Issue
Block a user