Refactoring based on IntelliJ static analysis