solidus_frontend 4.6.3 → 4.7.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
  SHA256:
3
- metadata.gz: cd7c9f5136e1d8c0a34583eeded4556cfc197bf7c82552959a6f23040fcc68a5
4
- data.tar.gz: 77bbe473baa884276813b58e59b32d5cff91cc373e683e81a0b08ad3fb88741c
3
+ metadata.gz: 5294035bcb041247624c2b5e25e0ffe1b12e3e3c9ac4f062e5c2f5ab4b5f6700
4
+ data.tar.gz: 893761e7a21db3961bdf924429d362f201bf2e02c7adab47ca5f7c0f72886a7e
5
5
  SHA512:
6
- metadata.gz: 9d045c73a0b8ce81cf2c6d85add6fd1faf8df8e8c41d81460969998764a6e469d9e9e84a827ccbca7a5091760944f9e8bd243c1f9e02698c834d1ec60f03031a
7
- data.tar.gz: f7eaa0e5cfd68aa5fdcc64ac278910ef1ca3571272dc589c1b811628097b6fcc6fba9ea6b70a69567e0c0c0d3d352075be9b830361bb3f50adc247ca390bc918
6
+ metadata.gz: 8395ea1b598f71430ea76f48933640fc919e982a709179ec1a260091e0326455e0a634bd27660aa4115986f42a487212407cc79a031da3e50437b2973bbcd409
7
+ data.tar.gz: f4ed0596aa980976745450b96408618c4d6ff0d9362205f5b0deaa5ab7b157ede1b8e099f3e0670444a72a88f1cb00846c10c8dcbbf4fbef5f26fdc8b400c361
@@ -4,7 +4,7 @@ on:
4
4
  push:
5
5
  branches:
6
6
  - main
7
- - v4.6
7
+ - v4.7
8
8
  pull_request:
9
9
  workflow_dispatch:
10
10
  schedule:
@@ -21,5 +21,5 @@ jobs:
21
21
  test:
22
22
  uses: solidusio/test-solidus-extension/.github/workflows/test.yml@main
23
23
  with:
24
- solidus_branches: '["v4.6"]'
24
+ solidus_branches: '["v4.7"]'
25
25
  ruby_versions: '["3.2", "3.4"]'
data/Gemfile CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  source 'https://rubygems.org'
4
4
 
5
- branch = ENV.fetch('SOLIDUS_BRANCH', 'v4.6')
5
+ branch = ENV.fetch('SOLIDUS_BRANCH', 'v4.7')
6
6
 
7
7
  # The storefront's promotion features build on the legacy promotion
8
8
  # system, which lives in the solidus_legacy_promotions gem since Solidus
@@ -6,13 +6,14 @@ module Spree
6
6
 
7
7
  respond_to :html
8
8
 
9
+ before_action :store_guest_token
9
10
  before_action :assign_order, only: :update
10
11
  # note: do not lock the #edit action because that's where we redirect when we fail to acquire a lock
11
12
  around_action :lock_order, only: :update
12
13
 
13
14
  def show
14
15
  @order = Spree::Order.find_by!(number: params[:id])
15
- authorize! :show, @order, params[:token] || cookies.signed[:guest_token]
16
+ authorize! :show, @order, cookies.signed[:guest_token]
16
17
  end
17
18
 
18
19
  def update
@@ -101,6 +102,10 @@ module Spree
101
102
 
102
103
  private
103
104
 
105
+ def store_guest_token
106
+ cookies.permanent.signed[:guest_token] = params[:token] if params[:token]
107
+ end
108
+
104
109
  def order_params
105
110
  if params[:order]
106
111
  params[:order].permit(*permitted_order_attributes)
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Spree
4
4
  module Frontend
5
- VERSION = "4.6.3"
5
+ VERSION = "4.7.0"
6
6
 
7
7
  def self.version
8
8
  VERSION
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solidus_frontend
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.6.3
4
+ version: 4.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Solidus Team