Merge remote-tracking branch 'origin/master' into develar/is
[idea/community.git] / java / java-analysis-impl / src / com / intellij / codeInspection / visibility / AccessCanBeTightenedInspection.java
index 004f02aecf8601224760ca130b45c074af03666d..99bb8c0417cbfb0ed2f55703504afc6e12697068 100644 (file)
@@ -83,7 +83,7 @@ class AccessCanBeTightenedInspection extends BaseJavaBatchLocalInspectionTool {
 
     public MyVisitor(@NotNull ProblemsHolder holder) {
       myHolder = holder;
-      InspectionProfile profile = InspectionProjectProfileManager.getInstance(holder.getProject()).getInspectionProfile();
+      InspectionProfile profile = InspectionProjectProfileManager.getInstance(holder.getProject()).getCurrentProfile();
       UnusedDeclarationInspectionBase tool = (UnusedDeclarationInspectionBase)profile.getUnwrappedTool(UnusedDeclarationInspectionBase.SHORT_NAME, holder.getFile());
       myDeadCodeInspection = tool == null ? new UnusedDeclarationInspectionBase() : tool;
     }