Fixed bug using the wrong model for simple relationships