File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
src/com/magento/idea/magento2plugin/inspections/php Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -175,7 +175,11 @@ private void checkParametersCompatibility(
175175 int index = 0 ;
176176 for (final Parameter pluginMethodParameter : pluginMethodParameters ) {
177177 index ++;
178- final String declaredType = pluginMethodParameter .getDeclaredType ().toString ();
178+ String declaredType = pluginMethodParameter .getDeclaredType ().toString ();
179+
180+ if (declaredType .isEmpty ()) {
181+ declaredType = pluginMethodParameter .getDocType ().toString ();
182+ }
179183
180184 if (index == 1 ) { //NOPMD
181185 final String targetClassFqn = Package .fqnSeparator .concat (targetClassName );
@@ -283,9 +287,8 @@ private void checkParametersCompatibility(
283287 final String targetMethodParameterDeclaredType =
284288 targetMethodParameter .getDeclaredType ().toString ();
285289
286- if (!checkTypeIncompatibility (
287- targetMethodParameterDeclaredType ,
288- declaredType )
290+ if (!checkTypeIncompatibility (targetMethodParameterDeclaredType , declaredType )
291+ && !pluginMethodParameter .getText ().contains ("...$" )
289292 ) {
290293 problemsHolder .registerProblem (
291294 pluginMethodParameter ,
You can’t perform that action at this time.
0 commit comments