fix entity relations save