media_types 0.5.5 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: faf9748b5c2757571da930bcebbf8216c9f639ca
4
- data.tar.gz: 5918fdae5f969af80f14687214edbf396a8f3a22
3
+ metadata.gz: 51e9f9e92cf850d365ca58a68a04f6791b095c89
4
+ data.tar.gz: 9669e70024f81a716c39e8a494e1b653db29d761
5
5
  SHA512:
6
- metadata.gz: 3168ce3f29ef159acb44c9abc5944b3cd3bb859b547760588a3b778edfb17f7ff2062a9ae64d76224a6fbbaf7286133e21b73b080904c15a773b399a9f15265f
7
- data.tar.gz: 604fdfbd5753e3c1e6656e8e124be298e34402edab4dfa006bffe4ab7e19848824e2a09a9787175a333da5ab2fd7efd3fee849036ca09c85ded1ded2ced6cfdd
6
+ metadata.gz: 6580805136858569152b54e947a464791e67cb398c151f57fe3200fcc1274ab2305fddafe18c958c038c66bbd0667565870ca89e7d34f3a73b11ddbc15bcfdd0
7
+ data.tar.gz: 60606b31427128bbc4a5bdd13068e7f5d2af90db2d698f86d618acce8ca31989283112dfd08daae7d1cf6012635234745a97f0127e26a21157c79727c1f09565
data/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ # 0.6.0
2
+
3
+ - Change default expected type for `attribute` to Object
4
+ - Remove default `actionpack` calls for `.register`
5
+ - Add integration for registering with `actionpack` (rails)
6
+ - Add integration for registering with `http` (http.rb)
7
+ - Fix stack overflow for cyclic schema
8
+
1
9
  # 0.5.5
2
10
 
3
11
  - Fix an issue with `attribute(optional:, &block)` not passing `optional:` to the created `collection`.
data/Gemfile.lock CHANGED
@@ -1,16 +1,56 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- media_types (0.5.5)
4
+ media_types (0.6.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
8
8
  specs:
9
+ actionpack (5.2.1)
10
+ actionview (= 5.2.1)
11
+ activesupport (= 5.2.1)
12
+ rack (~> 2.0)
13
+ rack-test (>= 0.6.3)
14
+ rails-dom-testing (~> 2.0)
15
+ rails-html-sanitizer (~> 1.0, >= 1.0.2)
16
+ actionview (5.2.1)
17
+ activesupport (= 5.2.1)
18
+ builder (~> 3.1)
19
+ erubi (~> 1.4)
20
+ rails-dom-testing (~> 2.0)
21
+ rails-html-sanitizer (~> 1.0, >= 1.0.3)
22
+ activesupport (5.2.1)
23
+ concurrent-ruby (~> 1.0, >= 1.0.2)
24
+ i18n (>= 0.7, < 2)
25
+ minitest (~> 5.1)
26
+ tzinfo (~> 1.1)
27
+ addressable (2.5.2)
28
+ public_suffix (>= 2.0.2, < 4.0)
9
29
  ansi (1.5.0)
10
30
  awesome_print (1.8.0)
11
31
  builder (3.2.3)
32
+ concurrent-ruby (1.0.5)
33
+ crass (1.0.4)
12
34
  docile (1.3.1)
35
+ domain_name (0.5.20180417)
36
+ unf (>= 0.0.5, < 1.0.0)
37
+ erubi (1.7.1)
38
+ http (3.3.0)
39
+ addressable (~> 2.3)
40
+ http-cookie (~> 1.0)
41
+ http-form_data (~> 2.0)
42
+ http_parser.rb (~> 0.6.0)
43
+ http-cookie (1.0.3)
44
+ domain_name (~> 0.5)
45
+ http-form_data (2.1.1)
46
+ http_parser.rb (0.6.0)
47
+ i18n (1.1.0)
48
+ concurrent-ruby (~> 1.0)
13
49
  json (2.1.0)
50
+ loofah (2.2.2)
51
+ crass (~> 1.0.2)
52
+ nokogiri (>= 1.5.9)
53
+ mini_portile2 (2.3.0)
14
54
  minitest (5.11.3)
15
55
  minitest-ci (3.4.0)
16
56
  minitest (>= 5.0.6)
@@ -19,6 +59,18 @@ GEM
19
59
  builder
20
60
  minitest (>= 5.0)
21
61
  ruby-progressbar
62
+ nokogiri (1.8.4-x64-mingw32)
63
+ mini_portile2 (~> 2.3.0)
64
+ oj (3.6.11)
65
+ public_suffix (3.0.3)
66
+ rack (2.0.5)
67
+ rack-test (1.1.0)
68
+ rack (>= 1.0, < 3)
69
+ rails-dom-testing (2.0.3)
70
+ activesupport (>= 4.2.0)
71
+ nokogiri (>= 1.6)
72
+ rails-html-sanitizer (1.0.4)
73
+ loofah (~> 2.2, >= 2.2.2)
22
74
  rake (10.5.0)
23
75
  ruby-progressbar (1.10.0)
24
76
  simplecov (0.16.1)
@@ -26,17 +78,26 @@ GEM
26
78
  json (>= 1.8, < 3)
27
79
  simplecov-html (~> 0.10.0)
28
80
  simplecov-html (0.10.2)
81
+ thread_safe (0.3.6)
82
+ tzinfo (1.2.5)
83
+ thread_safe (~> 0.1)
84
+ unf (0.1.4)
85
+ unf_ext
86
+ unf_ext (0.0.7.5-x64-mingw32)
29
87
 
30
88
  PLATFORMS
31
89
  x64-mingw32
32
90
 
33
91
  DEPENDENCIES
92
+ actionpack
34
93
  awesome_print
35
94
  bundler (~> 1.16)
95
+ http
36
96
  media_types!
37
97
  minitest (~> 5.0)
38
98
  minitest-ci
39
99
  minitest-reporters
100
+ oj
40
101
  rake (~> 10.0)
41
102
  simplecov
42
103
 
data/README.md CHANGED
@@ -4,6 +4,8 @@
4
4
  [![MIT license](http://img.shields.io/badge/license-MIT-brightgreen.svg)](http://opensource.org/licenses/MIT)
5
5
  [![Maintainability](https://api.codeclimate.com/v1/badges/6f2dc1fb37ecb98c4363/maintainability)](https://codeclimate.com/github/SleeplessByte/media-types-ruby/maintainability)
6
6
 
7
+ Media Types based on scheme, with versioning, views, suffixes and validations. Integrations available for [Rails](https://github.com/rails/rails) / ActionPack and [http.rb](https://github.com/httprb/http).
8
+
7
9
  ## Installation
8
10
 
9
11
  Add this line to your application's Gemfile:
@@ -25,8 +27,7 @@ Or install it yourself as:
25
27
  By default there are no media types registered or defined, except for an abstract base type.
26
28
 
27
29
  ## Definition
28
- You can define media types by inheriting from this base type, or create your own base type with a class method
29
- `.base_format` that is used to create the final media type string by injecting formatted parameters:
30
+ You can define media types by inheriting from this base type, or create your own base type with a class method `.base_format` that is used to create the final media type string by injecting formatted parameters:
30
31
 
31
32
  - `%<type>s`: the type `media_type` received
32
33
  - `%<version>s`: the version, defaults to `:current_version`
@@ -104,7 +105,7 @@ Adds an attribute to the schema, if a +block+ is given, uses that to test agains
104
105
  |-------|------|-------------|
105
106
  | key | `Symbol` | the attribute name |
106
107
  | opts | `Hash` | options to pass to `Scheme` or `Attribute` |
107
- | type | `Class`, `===`, Scheme | The type of the value, can be anything that responds to `===`, or scheme to use if no `&block` is given. Defaults to `String` without a `&block` and to Hash with a `&block`. |
108
+ | type | `Class`, `===`, Scheme | The type of the value, can be anything that responds to `===`, or scheme to use if no `&block` is given. Defaults to `Object` without a `&block` and to Hash with a `&block`. |
108
109
  | optional: | `TrueClass`, `FalseClass` | if true, key may be absent, defaults to `false` |
109
110
  | &block | `Block` | defines the scheme of the value of this attribute |
110
111
 
@@ -261,23 +262,6 @@ MyMedia.valid?({ _links: { self: { href: 'https://example.org/s' }, image: { hre
261
262
  # => true
262
263
  ```
263
264
 
264
-
265
- #### Link with extra attributes
266
- ```Ruby
267
- class MyMedia
268
- include MediaTypes::Dsl
269
-
270
- validations do
271
- link :image do
272
- attribute :templated, TrueClass
273
- end
274
- end
275
- end
276
-
277
- MyMedia.valid?({ _links: { self: { href: 'https://example.org/s' }, image: { href: 'https://image.org/i' }} })
278
- # => true
279
- ```
280
-
281
265
  #### Link with extra attributes
282
266
  ```Ruby
283
267
  class MyMedia
@@ -351,27 +335,48 @@ Venue.mime_type.view('active').to_s
351
335
  # => "application/vnd.mydomain.venue.v2.active+json"
352
336
  ```
353
337
 
354
- ## Register in Rails or Rack
355
- Define a `registrations` block on your media type, indicating the symbol for the base type (`registrations :symbol do`)
356
- and inside use the registrations dsl to define which media types to register. `versions array_of_numbers` determines which versions,
357
- `suffix name` adds a suffix, `type_alias name` adds an alias and `view name, symbol` adds a view.
338
+ ## Integrations
339
+ The integrations are not loaded by default, so you need to require them:
340
+ ```ruby
341
+ # For Rails / ActionPack
342
+ require 'media_types/integrations/actionpack'
343
+
344
+ # For HTTP.rb
345
+ require 'media_types/integrations/http'
346
+ ```
347
+
348
+ Define a `registrations` block on your media type, indicating the symbol for the base type (`registrations :symbol do`) and inside use the registrations dsl to define which media types to register. `versions array_of_numbers` determines which versions, `suffix name` adds a suffix, `type_alias name` adds an alias and `view name, symbol` adds a view.
358
349
 
359
- As long as `action_dispatch` is available, you can register the mime type with `action_dispatch/http/mime_type`:
360
350
  ```Ruby
361
351
  Venue.register
362
- # => Mime type is now available using the symbol, or lookup the actual mimetype
363
352
  ```
364
353
 
365
- You can do this in the `mime_types` initializer, or anywhere before your controllers are instantiated. Yes, the symbol
366
- (by default `<type>_v<version>_<suffix>`) can now be used in your `format` blocks, or as extension in the url.
354
+ ### Rails
355
+ Load the `actionpack` integration and call `.register` on all the media types you want to be available in Rails. You can do this in the `mime_types` initializer, or anywhere before your controllers are instantiated. Yes, the symbol (by default `<type>_v<version>_<suffix>`) can now be used in your `format` blocks, or as extension in the url.
356
+
357
+ Rails only has a default serializer for `application/json`, and content with your `+json` media types (or different once) will not be deserialized by default. A way to overcome this is to set the JSON parameter parser for all new symbols. `.register` gives you back an array of `Registerable` objects that responds to `#to_sym` to get that symbol.
358
+
359
+ ```ruby
360
+ symbols = Venue.register.map(&:to_sym)
361
+
362
+ original_parsers = ActionDispatch::Request.parameter_parsers
363
+ new_parser = original_parsers[Mime[:json].symbol]
364
+ new_parsers = original_parsers.merge(Hash[*symbols.map { |s| [s, new_parser] }])
365
+ ActionDispatch::Request.parameter_parsers = new_parsers
366
+ ```
367
+
368
+ If you want to validate the content-type and not have your errors be `Rack::Error` but be handled by your controllers, leave this out and add a `before_action` to your controller that deserializes + validates for you.
369
+
370
+ ### HTTP.rb
371
+ Load the `http` integration and call `.register` on all media types you want to be able to serialize and deserialize. The media type validations will run both before serialization and after deserialization.
372
+
373
+ Currently uses `oj` under the hood and this can not be changed.
367
374
 
368
375
  ## Development
369
376
 
370
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can
371
- also run `bin/console` for an interactive prompt that will allow you to experiment.
377
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
372
378
 
373
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the
374
- version number in `version.rb`, call `bundle exec rake release` to create a new git tag, push git commits and tags, and
379
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, call `bundle exec rake release` to create a new git tag, push git commits and tags, and
375
380
  push the `.gem` file to rubygems.org.
376
381
 
377
382
  ## Contributing
data/lib/media_types.rb CHANGED
@@ -8,30 +8,10 @@ require 'media_types/object'
8
8
  require 'media_types/scheme'
9
9
  require 'media_types/dsl'
10
10
 
11
- module MediaTypes
12
- # Shortcut used by #collection to #view('collection')
13
- COLLECTION_VIEW = 'collection'
14
-
15
- # Shortcut used by #index to #view('index')
16
- INDEX_VIEW = 'index'
17
-
18
- # Shortcut used by #create to #view('create')
19
- CREATE_VIEW = 'create'
20
-
21
- module_function
11
+ require 'media_types/views'
12
+ require 'media_types/integrations'
22
13
 
23
- ##
24
- # Called when Registerar#register is called
25
- # @param [Registerable] registerable
26
- def register(registerable)
27
- require 'action_dispatch/http/mime_type'
28
-
29
- mime_type = registerable.to_s
30
- symbol = registerable.to_sym
31
- synonyms = registerable.aliases
32
-
33
- Mime::Type.register(mime_type, symbol, synonyms)
34
- end
14
+ module MediaTypes
35
15
  end
36
16
 
37
17
 
@@ -59,21 +59,28 @@ module MediaTypes
59
59
  .version(defaults.fetch(:version) { nil })
60
60
  .suffix(defaults.fetch(:suffix) { nil })
61
61
  .view(defaults.fetch(:view) { nil })
62
+ self
62
63
  end
63
64
 
64
65
  def defaults(&block)
65
66
  return media_type_constructable unless block_given?
66
67
  self.media_type_constructable = Defaults.new(to_constructable, &block).to_constructable
68
+
69
+ self
67
70
  end
68
71
 
69
72
  def registrations(symbol = nil, &block)
70
73
  return media_type_registrar unless block_given?
71
74
  self.media_type_registrar = Registrar.new(self, symbol: symbol, &block)
75
+
76
+ self
72
77
  end
73
78
 
74
79
  def validations(&block)
75
80
  return media_type_validations unless block_given?
76
81
  self.media_type_validations = Validations.new(to_constructable, &block)
82
+
83
+ self
77
84
  end
78
85
  end
79
86
  end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module MediaTypes
4
+ INTEGRATION_METHODS = %i[register].freeze
5
+
6
+ module_function
7
+
8
+ def integrate(integration)
9
+ INTEGRATION_METHODS.each do |method|
10
+ next unless integration.respond_to?(method)
11
+ self.integrations = (integrations || {}).tap do |x|
12
+ x.merge!(method => (x[method] || []).concat([integration]))
13
+ end
14
+ end
15
+ end
16
+
17
+ # @!method register(registerable)
18
+ INTEGRATION_METHODS.each do |method|
19
+ define_singleton_method method do |*args, &block|
20
+ (integrations || {}).fetch(method) { [] }.each do |integration|
21
+ integration.send(method, *args, &block)
22
+ end
23
+ end
24
+
25
+ end
26
+
27
+ class << self
28
+ private
29
+
30
+ attr_accessor :integrations
31
+ end
32
+ end
@@ -0,0 +1,21 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'action_dispatch/http/mime_type'
4
+
5
+ module MediaTypes
6
+ module ActionPackIntegration
7
+
8
+ module_function
9
+
10
+ def register(registerable)
11
+ mime_type = registerable.to_s
12
+ symbol = registerable.to_sym
13
+ synonyms = registerable.aliases
14
+
15
+ Mime::Type.register(mime_type, symbol, synonyms)
16
+ end
17
+ end
18
+
19
+ integrate ActionPackIntegration
20
+ end
21
+
@@ -0,0 +1,47 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'http/mime_type'
4
+ require 'oj'
5
+
6
+ module MediaTypes
7
+ module HttpIntegration
8
+
9
+ module_function
10
+
11
+ def register(registerable)
12
+ mime_type = registerable.to_s
13
+
14
+ HTTP::MimeType.register_adapter mime_type, AdapterFor(registerable.media_type)
15
+ HTTP::MimeType.register_alias mime_type, registerable.to_sym
16
+
17
+ registerable.aliases.each do |alias_mime_type|
18
+ HTTP::MimeType.register_alias mime_type, alias_mime_type
19
+ end
20
+ end
21
+
22
+ class << self
23
+ private
24
+
25
+ # noinspection RubyInstanceMethodNamingConvention
26
+ def AdapterFor(media_type) # rubocop:disable Naming/MethodName
27
+ adapter_name = media_type.split(%r{[./_+-]}).map(&:capitalize).join('').tr('^A-z0-9', '_')
28
+
29
+ adapter = MediaTypes::HttpIntegration.const_set(adapter_name, Module.new)
30
+ adapter.define_singleton_method('encode') do |obj|
31
+ media_type.validate!(obj)
32
+ Oj.dump(obj, mode: :compat)
33
+ end
34
+
35
+ adapter.define_singleton_method('decode') do |str|
36
+ Oj.load(str, mode: :strict).tap do |result|
37
+ media_type.validate!(result)
38
+ end
39
+ end
40
+
41
+ adapter
42
+ end
43
+ end
44
+ end
45
+
46
+ integrate HttpIntegration
47
+ end
@@ -115,7 +115,8 @@ module MediaTypes
115
115
  # @param key [Symbol] the attribute name
116
116
  # @param opts [Hash] options to pass to Scheme or Attribute
117
117
  # @param type [Class, #===, Scheme] The type of the value, can be anything that responds to #===,
118
- # or scheme to use if no +&block+ is given. Defaults to String without a +&block+ and to Hash with a +&block+.
118
+ # or scheme to use if no +&block+ is given. Defaults to Object without a +&block+ and to Hash with a +&block+.
119
+ # or scheme to use if no +&block+ is given. Defaults to Object without a +&block+ and to Hash with a +&block+.
119
120
  #
120
121
  # @see Scheme::Attribute
121
122
  # @see Scheme
@@ -148,7 +149,7 @@ module MediaTypes
148
149
  # MyMedia.valid?({ foo: { bar: 'my-string' }})
149
150
  # # => true
150
151
  #
151
- def attribute(key, type = String, optional: false, **opts, &block)
152
+ def attribute(key, type = ::Object, optional: false, **opts, &block)
152
153
  if block_given?
153
154
  return collection(key, expected_type: ::Hash, optional: optional, **opts, &block)
154
155
  end
@@ -88,6 +88,8 @@ module MediaTypes
88
88
 
89
89
  def inspect(indent = 0)
90
90
  prefix = ' ' * indent
91
+ return "#{prefix}[Error]Depth limit reached[/Error]" if indent > 5_000
92
+
91
93
  [
92
94
  "#{prefix}[Rules n=#{keys.length} optional=#{optional_keys.length}]",
93
95
  "#{prefix} #{inspect_format_attribute(indent, '*', default)}",
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MediaTypes
4
- VERSION = '0.5.5'
4
+ VERSION = '0.6.0'
5
5
  end
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+
3
+ module MediaTypes
4
+ # Shortcut used by #collection to #view('collection')
5
+ COLLECTION_VIEW = 'collection'
6
+
7
+ # Shortcut used by #index to #view('index')
8
+ INDEX_VIEW = 'index'
9
+
10
+ # Shortcut used by #create to #view('create')
11
+ CREATE_VIEW = 'create'
12
+ end
data/media_types.gemspec CHANGED
@@ -23,11 +23,14 @@ Gem::Specification.new do |spec|
23
23
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
24
24
  spec.require_paths = ['lib']
25
25
 
26
+ spec.add_development_dependency 'actionpack'
26
27
  spec.add_development_dependency 'awesome_print'
27
28
  spec.add_development_dependency 'bundler', '~> 1.16'
29
+ spec.add_development_dependency 'http'
28
30
  spec.add_development_dependency 'minitest', '~> 5.0'
29
31
  spec.add_development_dependency 'minitest-ci'
30
32
  spec.add_development_dependency 'minitest-reporters'
33
+ spec.add_development_dependency 'oj'
31
34
  spec.add_development_dependency 'rake', '~> 10.0'
32
35
  spec.add_development_dependency 'simplecov'
33
36
  end
metadata CHANGED
@@ -1,15 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: media_types
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.5
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Derk-Jan Karrenbeld
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-04 00:00:00.000000000 Z
11
+ date: 2018-10-05 00:00:00.000000000 Z
12
12
  dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: actionpack
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
13
27
  - !ruby/object:Gem::Dependency
14
28
  name: awesome_print
15
29
  requirement: !ruby/object:Gem::Requirement
@@ -38,6 +52,20 @@ dependencies:
38
52
  - - "~>"
39
53
  - !ruby/object:Gem::Version
40
54
  version: '1.16'
55
+ - !ruby/object:Gem::Dependency
56
+ name: http
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
41
69
  - !ruby/object:Gem::Dependency
42
70
  name: minitest
43
71
  requirement: !ruby/object:Gem::Requirement
@@ -80,6 +108,20 @@ dependencies:
80
108
  - - ">="
81
109
  - !ruby/object:Gem::Version
82
110
  version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: oj
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
83
125
  - !ruby/object:Gem::Dependency
84
126
  name: rake
85
127
  requirement: !ruby/object:Gem::Requirement
@@ -132,6 +174,9 @@ files:
132
174
  - lib/media_types/dsl.rb
133
175
  - lib/media_types/formatter.rb
134
176
  - lib/media_types/hash.rb
177
+ - lib/media_types/integrations.rb
178
+ - lib/media_types/integrations/actionpack.rb
179
+ - lib/media_types/integrations/http.rb
135
180
  - lib/media_types/minitest/assert_media_type_format.rb
136
181
  - lib/media_types/minitest/assert_media_types_registered.rb
137
182
  - lib/media_types/object.rb
@@ -154,6 +199,7 @@ files:
154
199
  - lib/media_types/scheme/validation_options.rb
155
200
  - lib/media_types/validations.rb
156
201
  - lib/media_types/version.rb
202
+ - lib/media_types/views.rb
157
203
  - media_types.gemspec
158
204
  homepage: https://github.com/SleeplessByte/media-types-ruby
159
205
  licenses: []