<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -27,15 +27,15 @@ local ModelTag = cache.Tag:extend{
 }
 
 -- Slot of Model record by condition
-local ModelCondSlot = cache.Slot:extend{
+--[[local ModelCondSlot = cache.Slot:extend{
 	__tag = .....&quot;.ModelCondSlot&quot;;
 	init = function (self, backend, model, condition)
 		-- FIXME: too big serialize value
 		--cache.Slot.init(self, backend, model:tableName()..&quot;_&quot;..tostring(crypt.Md5(serialize(condition))):slice(1, 8))
-		cache.Slot.init(self, backend, model:tableName()..&quot;_&quot;..tostring(crypt.Md5(&quot;FIXME&quot;)):slice(1, 8))
+		cache.Slot.init(self, backend, model:tableName()..&quot;_&quot;..tostring(crypt.Md5(math.random())):slice(1, 8))
 		self:addTag(ModelTag(backend, model))
 	end;
-}
+}]]
 
 local Model = Struct:extend{
 	__tag = .....&quot;.Model&quot;;
@@ -233,11 +233,11 @@ local Model = Struct:extend{
 		end
 	end;
 	find = function (self, condition)
-		local cacher, cacheSlot, values = self:cacher()
+		--[[local cacher, cacheSlot, values = self:cacher()
 		if cacher then
 			cacheSlot = ModelCondSlot(cacher, self, condition)
-		end
-		values = cacheSlot and cacheSlot:thru(self):_loadOneByCond(condition) or self:_loadOneByCond(condition)
+		end]]
+		values = --[[cacheSlot and cacheSlot:thru(self):_loadOneByCond(condition) or]] self:_loadOneByCond(condition)
 		if not values then
 			return nil
 		end</diff>
      <filename>db/models.lua</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,4 @@
-local debug = debug
+local debug, tostring = debug, tostring
 local string = require &quot;luv.string&quot;
 local type, require, pairs, table, select, io, ipairs = type, require, pairs, table, select, io, ipairs
 local fields, Exception = require &quot;luv.fields&quot;, require &quot;luv.exceptions&quot;.Exception</diff>
      <filename>fields/references.lua</filename>
    </modified>
    <modified>
      <diff>@@ -269,7 +269,7 @@ models.Model.ajaxFieldHandler = function (self, data, preCond, postFunc)
 		return true
 	end
 	io.write(json.serialize{status=&quot;ok&quot;})
-	postFunc(f, obj)
+	if postFunc then postFunc(f, obj) end
 	return true
 end
 </diff>
      <filename>forms/init.lua</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>3de3e99786328c9d18f375196a3226f5974cfd79</id>
    </parent>
  </parents>
  <author>
    <name>Artyom Shein</name>
    <email>temiy@aisys.ru</email>
  </author>
  <url>http://github.com/temiy/luv/commit/5ae2accd3455ccb8986aa8b99852f9174562e240</url>
  <id>5ae2accd3455ccb8986aa8b99852f9174562e240</id>
  <committed-date>2009-11-03T00:54:10-08:00</committed-date>
  <authored-date>2009-11-03T00:54:10-08:00</authored-date>
  <message>Fixed bug with caching Model.find by condition.</message>
  <tree>acca585f7381c3a6838bc9c04d17d8312de054f4</tree>
  <committer>
    <name>Artyom Shein</name>
    <email>temiy@aisys.ru</email>
  </committer>
</commit>
