caprese 0.5.0 → 0.6.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ca3bb7c32744fab18ebfc77dc7e6cca7df12fd1e
4
- data.tar.gz: bbf6d26188979800498a2ae5310a7a56d860b9f5
3
+ metadata.gz: f278eb8df1a6036a2081b0a5f0f2639c20f8eda1
4
+ data.tar.gz: 8f03c23d45270aedfaeba0855e882f4e9cd338c3
5
5
  SHA512:
6
- metadata.gz: 74c741443c8b6e7d363bdb2675096b27ec23c7147d39522a9fea8b404d7dc07c48ef0f7ccdcc67eb120b3492a35592a12946879a4e34b4f4351cb02039586c37
7
- data.tar.gz: 2166985f7b64d5d99c5f671001430393b533d3d90a14b8231fc67ab1c79f0a233e90a46ab6f084f7c3121866521a38d85bef8b495731c19187c672111312d8e2
6
+ metadata.gz: 048c8c9084732524a1bed4155a0e97985c2f7fd3a24351ae9db7d3e439cf34442ae010b560dc3fc1e2b82010267001073737196ea627ff7e4898d4e7243035f9
7
+ data.tar.gz: 1700cf22a6ca82eaf58c2db49cb3b403d351b8b056c63bbd0f0354820232b49690ccd1e99c61b56b26440b7ed2bd9abb98a074536cab18bbce79f9ba9fee8953
data/CHANGELOG.md CHANGED
@@ -178,4 +178,8 @@
178
178
  * Allows `PATCH` requests to primary endpoints that update autosaving collection relationships to propagate the nested errors on attributes/relationships up to the primary data so error source pointers are just as detailed as they would be under `POST` requests already
179
179
  * Fields are now assigned in a specific order: attributes, singular relationships, collection relationships
180
180
  * Fix issue regarding `:base` field titles interpolated into error messages
181
- * Add more detailed error responses to `update_relationship_definition` endpoints
181
+ * Add more detailed error responses to `update_relationship_definition` endpoints
182
+
183
+ ## 0.6.0
184
+
185
+ * Accept and respond with `Content-Type: application/vnd.api+json`
@@ -28,6 +28,8 @@ module Caprese
28
28
  end
29
29
  end
30
30
 
31
+ headers['Content-Type'] = Caprese.config.content_type
32
+
31
33
  super
32
34
  end
33
35
 
@@ -1,3 +1,3 @@
1
1
  module Caprese
2
- VERSION = '0.5.0'
2
+ VERSION = '0.6.0'
3
3
  end
data/lib/caprese.rb CHANGED
@@ -15,6 +15,10 @@ module Caprese
15
15
  # Defines the ActiveModelSerializers adapter to use when serializing
16
16
  config.adapter ||= :json_api
17
17
 
18
+ # Defines the full Content-Type header to respond with
19
+ # @note Caprese accepts both application/json and application/vnd.api+json
20
+ config.content_type = 'application/vnd.api+json; charset=utf-8'
21
+
18
22
  # Define URL options for use in UrlHelpers
19
23
  config.default_url_options ||= {}
20
24
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: caprese
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Landgrebe
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2017-12-08 00:00:00.000000000 Z
13
+ date: 2018-01-04 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: active_model_serializers
@@ -272,4 +272,3 @@ signing_key:
272
272
  specification_version: 4
273
273
  summary: Opinionated Rails library for writing RESTful APIs
274
274
  test_files: []
275
- has_rdoc: