mirror of
https://github.com/github/codeql.git
synced 2026-04-30 03:05:15 +02:00
JS: Update OK-style comments to $-style
This commit is contained in:
@@ -6,8 +6,8 @@ class C extends Q {
|
||||
*/
|
||||
this.x = this.x; // OK - documentation
|
||||
|
||||
this.y = this.y; // NOT OK
|
||||
this.y = this.y; // $ Alert
|
||||
|
||||
this.arg = this.arg; // NOT OK
|
||||
this.arg = this.arg; // $ Alert
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
function Rectangle(x, y, width, height) {
|
||||
this.x = x;
|
||||
this.y = y;
|
||||
// NOT OK
|
||||
width = width;
|
||||
width = width; // $ Alert
|
||||
this.height = height;
|
||||
}
|
||||
|
||||
@@ -15,18 +14,16 @@ Rectangle.prototype = {
|
||||
this.width = a/this.height;
|
||||
},
|
||||
foo: function() {
|
||||
// OK
|
||||
|
||||
this.area = this.area;
|
||||
}
|
||||
};
|
||||
|
||||
// NOT OK
|
||||
array[1] = array[1];
|
||||
array[1] = array[1]; // $ Alert
|
||||
|
||||
o.x = o.x; // $ Alert
|
||||
|
||||
// NOT OK
|
||||
o.x = o.x;
|
||||
|
||||
// OK
|
||||
document.innerHTML = document.innerHTML;
|
||||
|
||||
class Point {
|
||||
@@ -43,7 +40,7 @@ class Point {
|
||||
this.y = 0;
|
||||
}
|
||||
foo() {
|
||||
// OK
|
||||
|
||||
this.dist = this.dist;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user