mirror of
https://github.com/github/codeql.git
synced 2025-12-17 17:23:36 +01:00
19 lines
357 B
JavaScript
19 lines
357 B
JavaScript
(function(){
|
|
var v;
|
|
(function(){
|
|
if(typeof v === "undefined"){ // NOT OK
|
|
v = 42;
|
|
}
|
|
for(var v in x){
|
|
}
|
|
});
|
|
});
|
|
|
|
const isFalsyObject = (v) => typeof v === 'undefined' && v !== undefined; // OK
|
|
|
|
function f(v) {
|
|
if (typeof v === 'undefined' && v !== undefined) { // OK
|
|
doSomething(v);
|
|
}
|
|
}
|