ソースを参照

Fixed bug in cache.get() method

@soyjavi 14 年 前
コミット
4f4349cda9
1 ファイル変更3 行追加3 行削除
  1. 3 3
      src/data/Lungo.Data.Cache.js

+ 3 - 3
src/data/Lungo.Data.Cache.js

@@ -1,6 +1,6 @@
-/** 
+/**
  * Temporary cache system
- * 
+ *
  * @namespace LUNGO.Data
  * @class Cache
  *
@@ -41,7 +41,7 @@ LUNGO.Data.Cache = (function(lng, undefined) {
         if (arguments.length === 1) {
             return _cache[key];
         } else {
-            return _cache[arguments[0]][arguments[1]];
+            return (_cache[arguments[0]]) ? _cache[arguments[0]][arguments[1]] : undefined;
         }
     };