From 3e9c2d581fc8f470bcda02e45ae6ee2707af6767 Mon Sep 17 00:00:00 2001 From: Jinzhu Date: Mon, 26 Jan 2015 17:59:31 +0800 Subject: [PATCH] Fix duplicated instanceId in edge case --- scope.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scope.go b/scope.go index 6a1c692e..698ed0bb 100644 --- a/scope.go +++ b/scope.go @@ -502,7 +502,7 @@ func (scope *Scope) Get(name string) (interface{}, bool) { // InstanceId get InstanceId for scope func (scope *Scope) InstanceId() string { if scope.instanceId == "" { - scope.instanceId = fmt.Sprintf("%v", &scope) + scope.instanceId = fmt.Sprintf("%v%v", &scope, &scope.db) } return scope.instanceId }