Throwable reason = e.getReason();
String msg = "Caught OgnlException while setting property '" + name + "' on type '" + o.getClass().getName() + "'.";
Throwable exception = (reason == null) ? e : reason;
if (throwPropertyExceptions) {
throw new ReflectionException(msg, exception);
} else {
if (devMode) {
LOG.warn(msg, exception);
}
}