Fixes to export to RoR