What I don't get is how folks deal with Exceptions coming from NH objects
since this behaviour was introduced.
I mean EVER error thrown from Domain Objects needs to have the
innerExceptionChecked.
Is everyone doing this?
using (var tran = _session.BeginTransaction())
{
var customer = _session.Get<Customer>(1);
try {
customer.DoSomething();
}
catch(TargetInvocationException ex){
var realExecption = ex.InnnerException;
//Check Exception Type, do some logic etc...
}
tran.Commit();
}
It's madness. Yes I understand why it's happening and I get it I just don't
see that its at all useful from a dev standpoint.
Mark
--
You received this message because you are subscribed to the Google Groups
"nhusers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/nhusers.
For more options, visit https://groups.google.com/d/optout.