diff --git a/src/main/java/org/apache/maven/shared/filtering/BaseFilter.java b/src/main/java/org/apache/maven/shared/filtering/BaseFilter.java index 0740dae..c36df9f 100644 --- a/src/main/java/org/apache/maven/shared/filtering/BaseFilter.java +++ b/src/main/java/org/apache/maven/shared/filtering/BaseFilter.java @@ -288,16 +288,18 @@ private static Interpolator createInterpolator( interpolator.addValueSource(propertiesValueSource); if (project != null) { - interpolator.addValueSource(new PrefixedObjectValueSource(projectStartExpressions, project, true) { - @Override - public Object getValue(String expression) { - Object value = super.getValue(expression); - if (value instanceof Optional) { - value = ((Optional) value).orElse(null); + for (Object root : new Object[] {project, project.getModel()}) { + interpolator.addValueSource(new PrefixedObjectValueSource(projectStartExpressions, root, true) { + @Override + public Object getValue(String expression) { + Object value = super.getValue(expression); + if (value instanceof Optional) { + value = ((Optional) value).orElse(null); + } + return value; } - return value; - } - }); + }); + } } if (mavenSession != null) {