浏览代码

Try to getFromCache in getWithKeys

Pascal Peridont 19 年之前
父节点
当前提交
332004c8c2
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      std/neko/db/Manager.hx

+ 3 - 0
std/neko/db/Manager.hx

@@ -95,6 +95,9 @@ class Manager<T : Object> {
 	}
 
 	public function getWithKeys( keys : {} ) : T {
+		var x = getFromCache(untyped keys,false);
+		if( x != null )
+			return x;
 		var s = new StringBuf();
 		s.add("SELECT * FROM ");
 		s.add(table_name);