Fix relationships

ToMany relationships are now stored as child nodes in Firebase rather
than as JSON arrays. Existing relationships will need to be converted
to the new format.