puzzly_api_plugin 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/puzzly_api_plugin/version.rb +1 -1
- data/lib/puzzly_api_plugin/view/cache.rb +9 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a8082885784677369a4fca2ac59e71f12657ffa9314b4fe9c1acc04c7cb333e6
|
4
|
+
data.tar.gz: 79ba78676069453e25743baf5d11aafb18d630be42ad5bb388d2558b594f24d5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d0d1890ed66577babf8259f7c617e97417f9e819f9ac3cd8ad0db71d4b05bd7e3fb4fadf66c90818296b2eca72679825f3dc8c76e8547dfa6163095d666a2228
|
7
|
+
data.tar.gz: 57a447f7b1fa6ca3fcccce27cfe3a82c64e6b587844a2256a1e49d90901e799ff9bf1c1e86ba66c200bf6c8c8a39daa5269ae9d1a38318c15c421efaf2c77f3c
|
@@ -4,16 +4,23 @@ module PuzzlyApiPlugin
|
|
4
4
|
class CacheView < Renderable
|
5
5
|
def self.create(cache)
|
6
6
|
mod = ModulesCollection.instance.get_by_id cache.module_id
|
7
|
+
schema = nil
|
7
8
|
|
8
|
-
|
9
|
+
if(!cache.schema_id.nil?)
|
10
|
+
schema = SchemasCollection.instance.get_by_id cache.schema_id
|
11
|
+
end
|
12
|
+
|
13
|
+
CacheView.new(mod.to_identity, schema,
|
9
14
|
cache)
|
10
15
|
end
|
11
16
|
|
12
|
-
def initialize(mod, cache)
|
17
|
+
def initialize(mod, schema, cache)
|
13
18
|
cache.copy_to_hash self
|
14
19
|
self.delete MetadataFields::MODULE_ID
|
20
|
+
self.delete MetadataFields::SCHEMA_ID
|
15
21
|
|
16
22
|
self[MetadataFields::MODULE] = mod
|
23
|
+
self[MetadataFields::SCHEMA] = schema
|
17
24
|
end
|
18
25
|
end
|
19
26
|
end
|