dtk_crd_parser 0.0.147 → 0.0.148
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/crd_parser/component.rb +10 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bab9c0e14abd0a81fd140d2b2e6604741de19f70
|
4
|
+
data.tar.gz: f64626b39ee898e2121af3f39848192b3da5fec9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 897e4f74ff3c2846a510f15cfcb5f97fda65a91c188678cecb0b99c3e4a59e8161f5e740026d352fa6b1f9dba65b147708b56f8b74016f87e64f141dd0bda579
|
7
|
+
data.tar.gz: 554538b672b7b8c43fc1f5ade54d336805bb24f4cf3abad670c1ef4b2b5d4c8abfe306faca761c037caa1a580944f50ec4d7944e3258fe414a994f189d91a6a0
|
data/lib/crd_parser/component.rb
CHANGED
@@ -38,14 +38,21 @@ module DTK::CrdParser
|
|
38
38
|
protected
|
39
39
|
|
40
40
|
def self.getComponentAttributes(fullComponentName, components)
|
41
|
-
component =
|
42
|
-
|
43
|
-
componentObj = component[(component.to_h).keys.first.to_s] if (fullComponentName == name)
|
41
|
+
component = components.each do |component|
|
42
|
+
componentObj = component[fullComponentName]
|
44
43
|
if(componentObj && componentObj.is_a?(Kubeclient::Resource))
|
45
44
|
return componentObj[:attributes]
|
46
45
|
end
|
47
46
|
end
|
48
47
|
return nil
|
48
|
+
# component = (components || []).each do |component|
|
49
|
+
# name = (component.to_h).keys.first.to_s.gsub!('_', '-')
|
50
|
+
# componentObj = component[(component.to_h).keys.first.to_s] if (fullComponentName == name)
|
51
|
+
# if(componentObj && componentObj.is_a?(Kubeclient::Resource))
|
52
|
+
# return componentObj[:attributes]
|
53
|
+
# end
|
54
|
+
# end
|
55
|
+
# return nil
|
49
56
|
end
|
50
57
|
end
|
51
58
|
end
|