PsiElement (DataContext dataContext, PsiElement targetContainer) { if (targetContainer instanceof PsiPackage) { final Module module = LangDataKeys.TARGET_MODULE.getData(dataContext); if (module != null) { final PsiDirectory[] directories = ((PsiPackage)targetContainer).getDirectories(GlobalSearchScope.moduleScope(module)); if (directories.length == 1) { return directories[0]; } } } return super.adjustTargetForMove(dataContext, targetContainer); }