spree_api 4.0.2 → 4.0.3

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of spree_api might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7c0e5548a962fc184efb5acee56e3349d2280f77ee6f3cec4cf96f57f1ca6790
4
- data.tar.gz: 7179cfd1aa74207e58e54e8b6aff45110ece30b043a3d9ee57e5bc0ad31fe15b
3
+ metadata.gz: fde99f29c7162d1e5aa807bedaee13a5ad7da6f09ff841ea4e1f80cd6bb901e9
4
+ data.tar.gz: 11c11b3012259a69072fb6ba9c90bc5373436f17aa74f93e09f13b2a9d23189f
5
5
  SHA512:
6
- metadata.gz: 39b32f8a83d3cad4028f6719adb391ab5b710b7049735aef350823f88116e373ba657880726c38e26f12860aaa6d850aa7a42f004b556acdf4c9bc5b45c92bca
7
- data.tar.gz: 1086592c64ae7bbb78188e2db63295c021d5ce3f389ee79ee86cda9b50b1c8b9b7e36e67afed01f2e7463f3a920a263b999fb5dbacd297852d58640c90e42fb1
6
+ metadata.gz: 0b82f3921072e81146d1483fb2f59bf9d2c18542646c9bfb52773bd3c3753c5a57a7206fe421f84a4ccfe7ee42c5770e4c91f3436bff7e7b02eb93033ff977f8
7
+ data.tar.gz: 6cab7055aa44a7723bd1e042fa58428093d652ef2e0ec8d3af0dafc2422a64471aabd3d3ec646e7358ffa29ceef20595268d256b37079edac51043f4e6a97e72
@@ -5,6 +5,8 @@ module Spree
5
5
  class OrderStatusController < ::Spree::Api::V2::BaseController
6
6
  include Spree::Api::V2::Storefront::OrderConcern
7
7
 
8
+ before_action :ensure_order_token
9
+
8
10
  def show
9
11
  render_serialized_payload { serialize_resource(resource) }
10
12
  end
@@ -25,6 +27,10 @@ module Spree
25
27
  def resource_serializer
26
28
  Spree::Api::Dependencies.storefront_cart_serializer.constantize
27
29
  end
30
+
31
+ def ensure_order_token
32
+ raise ActiveRecord::RecordNotFound unless order_token
33
+ end
28
34
  end
29
35
  end
30
36
  end
@@ -162,6 +162,8 @@ paths:
162
162
  - $ref: '#/components/parameters/OrderParam'
163
163
  - $ref: '#/components/parameters/CartIncludeParam'
164
164
  - $ref: '#/components/parameters/SparseFieldsParam'
165
+ security:
166
+ - orderToken: []
165
167
  '/cart':
166
168
  post:
167
169
  description: >-
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spree_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.2
4
+ version: 4.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Bigg
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-11-21 00:00:00.000000000 Z
11
+ date: 2019-12-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jsonapi-rspec
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 4.0.2
33
+ version: 4.0.3
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 4.0.2
40
+ version: 4.0.3
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rabl
43
43
  requirement: !ruby/object:Gem::Requirement