Fixes #1 where unique property is causing index errors.
Merge