Fix equality expression in ternary operator (#34225)
The equality comparison expression (==) should be used instead of assignment (=)pull/34243/head
parent
d1c5f51792
commit
9900699d0b
|
@ -10,7 +10,7 @@ Use ternary operator to check for equality.
|
|||
|
||||
```javascript
|
||||
function checkEqual(a, b) {
|
||||
return (a = b ? true : false );
|
||||
return (a == b ? true : false );
|
||||
}
|
||||
|
||||
checkEqual(1, 2);
|
||||
|
|
Loading…
Reference in New Issue