atmire-1406 Fix the null point error in getting the owning collection