anchela commented on a change in pull request #88:
URL:
https://github.com/apache/sling-org-apache-sling-feature-cpconverter/pull/88#discussion_r662997482
##########
File path:
src/main/java/org/apache/sling/feature/cpconverter/handlers/AbstractConfigurationEntryHandler.java
##########
@@ -33,7 +33,7 @@
private boolean enforceConfigurationBelowConfigFolder;
public AbstractConfigurationEntryHandler(@NotNull String extension) {
-
super("/jcr_root/(?:apps|libs)/.+/(?<foldername>config|install)(\\.(?<runmode>[^/]+))?/(?<pid>.*)\\."
+ extension);
+
super("/jcr_root/(?:apps|libs)/.+/(?<foldername>config|install)(\\.(?<runmode>[^/]+))?(.*)/(?<pid>[^\\/]*)\\."
+ extension + ("(?<dir>.dir(/\\.content\\.xml)?)?$"));
}
void setEnforceConfgurationBelowConfigFolder(boolean
enforceConfigurationBelowConfigFolder) {
Review comment:
with the additional if for 'dir' the method gets quite complex. i would
suggest to refactor it to reduce overall complexity
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]