Of course we could fix it using search/replace but it’s not the JetBrains way! We have a powerful IDE helping us, right?

So instead, we’ve used the project-wide code analysis and applied a quick-fix to correct the incompatibility. The 4 steps below show how exactly this is achieved:

1. Select Code | Inspect Code from the main menu. Choose a scope to analyze (project, a directory, or other) and inspections to run.

2. You can select a set of inspections to execute by specifying an Inspection profile

3. RubyMine inspects the code and shows the Inspection Results in a separate tool-window. The results are grouped by categories. You can browse, see the problem descriptions and reported files. Also for each problem RubyMine suggests a resolution, that can be executed for a file right away.

4. But you can select an item in inspection results, right-click it and choose to ‘Apply Fix…’. This instantly fixes all the below warnings.

And this is it. Try it! You may discover some interesting things about your projects.