Check for undefined value

If where[i].w[k] is tested for null and not also undefined then 
when saving a Model in Node-Orm2 that has a hasMany relationship defined the 
save crashes.
Merge pull request #2 from Gamaroff/patch-1

Check for undefined value