1
0
Fork 0
mirror of https://github.com/Sonarr/Sonarr synced 2025-02-21 13:47:10 +00:00

Prevent page crash on console.error being used with non-string values

This commit is contained in:
Bogdan 2025-01-21 16:13:18 +02:00 committed by Mark McDowall
parent 970df1a1d8
commit 963395b969

View file

@ -23,12 +23,13 @@ const error = console.error;
function logError(...parameters: any[]) {
const filter = parameters.find((parameter) => {
return (
parameter.includes(
typeof parameter === 'string' &&
(parameter.includes(
'Support for defaultProps will be removed from function components in a future major release'
) ||
parameter.includes(
'findDOMNode is deprecated and will be removed in the next major release'
)
parameter.includes(
'findDOMNode is deprecated and will be removed in the next major release'
))
);
});