Fixed priority order of events
Merge pull request #64 from hAdamm/as-bugFix

Fixed priority order of events
Added clearing properties changes after insert or update of entity