From 675bbca66732fcf9d98af6166af8115b0eb92c09 Mon Sep 17 00:00:00 2001 From: Bojan Petrovic Date: Wed, 21 Oct 2015 14:49:49 +0200 Subject: [PATCH] Fix compilation --- scope_private.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scope_private.go b/scope_private.go index 88632c3a..d552a3d8 100755 --- a/scope_private.go +++ b/scope_private.go @@ -418,7 +418,7 @@ func (scope *Scope) related(value interface{}, foreignKeys ...string) *Scope { if relationship := fromField.Relationship; relationship != nil { if relationship.Kind == "many_to_many" { joinTableHandler := relationship.JoinTableHandler - scope.Err(joinTableHandler.JoinWith(joinTableHandler, toScope.db, scope.Value).Find(value).Error) + scope.Err(joinTableHandler.JoinWith(toScope.db, scope.Value).Find(value).Error) } else if relationship.Kind == "belongs_to" { sql := fmt.Sprintf("%v = ?", scope.Quote(toScope.PrimaryKey())) foreignKeyValue := fromFields[relationship.ForeignDBName].Field.Interface()