Skip to content

Commit

Permalink
Merge pull request #5 from mlaggner/master
Browse files Browse the repository at this point in the history
fix: only call methods with zero parameters
  • Loading branch information
DJCordhose committed Sep 11, 2015
2 parents 4987bac + e780e04 commit e30b0e5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/com/floreysoft/jmte/DefaultModelAdaptor.java
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,8 @@ protected Object getPropertyValue(Object o, String propertyName) {
for (Method method : declaredMethods) {
if (Modifier.isPublic(method.getModifiers())
&& (method.getName().equals("get" + suffix) || method
.getName().equals("is" + suffix))) {
.getName().equals("is" + suffix))
&& method.getParameterTypes().length == 0) {
value = method.invoke(o, (Object[]) null);
valueSet = true;
member = method;
Expand Down

0 comments on commit e30b0e5

Please sign in to comment.