refactored idea plugin