Changes to handle new data model

Pedant :P