OSDN Git Service

operator move to cache
[pettanr/pettanr.git] / app / assets / javascripts / models / comic.js.coffee
index 98973a0..beb41f2 100644 (file)
@@ -16,7 +16,7 @@ class Pettanr.Comic extends Peta.Binder
   author: () ->\r
     new Pettanr.Cache.Retriever(Pettanr.Author, @get('author_id'))\r
   \r
-  is_visible: (operators) ->\r
+  is_visible: (operators = Pettanr.cache.operators) ->\r
     switch super(operators)\r
       when null\r
         return true\r
@@ -26,7 +26,7 @@ class Pettanr.Comic extends Peta.Binder
         @get('visible') > 0\r
   \r
   overwrite: (options) ->\r
-    operators = options.operators\r
+    operators = Pettanr.cache.operators\r
     return false if not operators.author\r
     @set('author_id', operators.author.id)\r
   \r