capricorn 2.0.9 → 2.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -178,12 +178,12 @@ app_to_json(App) ->
178
178
  {<<"root_path">>, App#application.root_path},
179
179
  {<<"installed_gems">>, lists:foldl(fun(Gem, Acc1) ->
180
180
  [gem_id_to_json(Gem) |Acc1]
181
- end, [], App#application.required_gems)},
181
+ end, [], App#application.installed_gems)},
182
182
  {<<"required_gems">>, App#application.required_gems}
183
183
  ]}.
184
184
 
185
185
 
186
- gem_id_to_json(Gem) ->
186
+ gem_id_to_json(#gem_id{}=Gem) ->
187
187
  % -record(gem_id, {
188
188
  % name :: binary(),
189
189
  % version :: version()
@@ -209,6 +209,11 @@ gem_id_to_json(Gem) ->
209
209
 
210
210
  {[
211
211
  {<<"name">>, Gem#gem_id.name},
212
- {<<"version">>, ?l2b(Version)}
213
- ]}.
214
-
212
+ {<<"version">>, case Version of
213
+ undefined -> null;
214
+ Else -> ?l2b(Version)
215
+ end}
216
+ ]};
217
+
218
+ gem_id_to_json(_) ->
219
+ null.
@@ -1,5 +1,5 @@
1
1
  module Capricorn
2
2
 
3
- VERSION = '2.0.9'
3
+ VERSION = '2.0.10'
4
4
 
5
5
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capricorn
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 2
8
8
  - 0
9
- - 9
10
- version: 2.0.9
9
+ - 10
10
+ version: 2.0.10
11
11
  platform: ruby
12
12
  authors:
13
13
  - Simon Menke