fixing relations/edit - js timing issues