Handle error copying stream id to clipboard

This commit is contained in:
Max Goodman
2020-07-07 22:18:22 -07:00
parent 23fd36ced7
commit 37751774b3

View File

@@ -287,7 +287,11 @@ function App({ wsEndpoint }) {
const handleClickId = useCallback(
(streamId) => {
navigator.clipboard.writeText(streamId)
try {
navigator.clipboard.writeText(streamId)
} catch (err) {
console.warn('Unable to copy stream id to clipboard:', err)
}
if (focusedInputIdx !== undefined) {
handleSetView(focusedInputIdx, streamId)