correct bug in relationship creation