Skip to content

Commit 25406d3

Browse files
authored
#82 Improve inspection description (#150)
1 parent 9a32131 commit 25406d3

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ You can deprecate some PhpDoc tags in your project.
4242
#### GlobalVariableUsage
4343
This inspection detects usages of global variables.
4444
```php
45-
echo $_GET['name']; // <-- Deprecated global variable usage
45+
echo $_GET['name']; // <-- Global variable usage
4646
```
4747
#### MethodCanBePrivate
4848
Protected methods can be converted to private.
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
This inspection detects usages of global variables.
22
<pre>
3-
echo $_GET['name']; // <-- Deprecated global variable usage
3+
echo $_GET['name']; // <-- Global variable usage
44
</pre>
55
<!-- main -->

src/main/kotlin/com/funivan/idea/phpClean/inspections/globalVariableUsage/GlobalVariableUsageInspection.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ class GlobalVariableUsageInspection : PhpCleanInspection() {
2727
if (names.contains(variable.name)) {
2828
holder.registerProblem(
2929
variable,
30-
"Deprecated global variable usage"
30+
"Global variable usage"
3131
)
3232
}
3333
}
3434
}
3535
}
3636

3737

38-
}
38+
}

src/test/kotlin/com/funivan/idea/phpClean/inspections/globalVariableUsage/GlobalVariableUsageInspectionTest.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ class GlobalVariableUsageInspectionTest : BaseInspectionTest() {
88
assert(
99
GlobalVariableUsageInspection(),
1010
"""<?php
11-
echo <warning descr="Deprecated global variable usage">${'$'}_GET</warning>['name'];
11+
echo <warning descr="Global variable usage">${'$'}_GET</warning>['name'];
1212
"""
1313
)
1414
}
15-
}
15+
}

0 commit comments

Comments
 (0)