From 8b40db4bcb6eb094537dbcbde662b670eeb9c6e0 Mon Sep 17 00:00:00 2001 From: t0pep0 Date: Fri, 27 Jun 2014 19:14:12 +0400 Subject: [PATCH] fix bug --- cache.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cache.go b/cache.go index ca3e75c..71a2315 100644 --- a/cache.go +++ b/cache.go @@ -113,6 +113,10 @@ func (item *Item) addItem(res *Item) { if res == nil { return } + if item == nil { + item = res + return + } if item.Object == nil { item.copy(res) return