solidus_core 2.11.12 → 2.11.13

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
  SHA256:
3
- metadata.gz: a34b58af2575a9f4916aa79bdb8b968887685a642e1087c417ed186475762142
4
- data.tar.gz: 774a645e0ab71b87649d6f9d2b30366a2dd6e308a7ac41dbfa7d144ad392dffa
3
+ metadata.gz: c51ec975ec9a598a8c62ab1921bb8fd36205632e56145bca20b986f3ff89f07d
4
+ data.tar.gz: 81302c9de608750a7452ad64b380a4b0a1932ba4b477a26e828c5937fc39988f
5
5
  SHA512:
6
- metadata.gz: ffadd725195f8e3909d8c8f67adf4fe8e7176c5af9e436160028be10a4bb06b1871178d7ec88540320811093ee924fde68e0e13c3fdb1c5ee59124a66e792f44
7
- data.tar.gz: f2a49eaa1d162dfd28500b6ea14e7e37a622ba471f9bec40d51b0a4f20b8c4291b662e0632471d9ef8fa11520644cfab142d93032888e8aae68889ff1e2d1673
6
+ metadata.gz: df514483ac9eb9d69d4063962bac359715920135901a6646be17e06f6303b1683475f46a2e4c5a4a1f66d5349720b3543dd0990ee986a1670fcfeb2e17496253
7
+ data.tar.gz: 6d1162cfaa6bedd3a748f3ea729d7134f98be6e75117312bf206748fba31120e5888023b1954f7c65f7a5b51422316b317afc483dcff0c37a4c1790648f1a111
@@ -12,7 +12,7 @@ module Spree
12
12
  # end
13
13
  #
14
14
  class EmailValidator < ActiveModel::EachValidator
15
- EMAIL_REGEXP = /\A([^@\.]|[^@\.]([^@\s]*)[^@\.])@([^@\s]+\.)+[^@\s]+\z/
15
+ EMAIL_REGEXP = URI::MailTo::EMAIL_REGEXP
16
16
 
17
17
  def validate_each(record, attribute, value)
18
18
  unless EMAIL_REGEXP.match? value
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Spree
4
- VERSION = "2.11.12"
4
+ VERSION = "2.11.13"
5
5
 
6
6
  def self.solidus_version
7
7
  VERSION
@@ -5,7 +5,7 @@ module Spree
5
5
  module BlacklistUrls
6
6
  def setup_url_blacklist(browser)
7
7
  if browser.respond_to?(:url_blacklist)
8
- browser.url_blacklist = ['http://fonts.googleapis.com']
8
+ browser.url_blacklist = ['https://fonts.googleapis.com']
9
9
  end
10
10
  end
11
11
  end
@@ -0,0 +1,18 @@
1
+ # frozen_string_literal: true
2
+
3
+ namespace :solidus do
4
+ desc 'Prints orders with invalid email (after fix for GHSA-qxmr-qxh6-2cc9)'
5
+ task check_orders_with_invalid_email: :environment do
6
+ matches = Spree::Order.find_each.reduce([]) do |matches, order|
7
+ order.email.nil? || Spree::EmailValidator::EMAIL_REGEXP.match?(order.email) ? matches : matches + [order]
8
+ end
9
+ if matches.any?
10
+ puts 'Email / ID / Number'
11
+ puts(matches.map do |order|
12
+ "#{order.email} / #{order.id} / #{order.number}"
13
+ end.join("\n"))
14
+ else
15
+ puts 'NO MATCHES'
16
+ end
17
+ end
18
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solidus_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.11.12
4
+ version: 2.11.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Solidus Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-11-17 00:00:00.000000000 Z
11
+ date: 2021-12-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionmailer
@@ -942,6 +942,7 @@ files:
942
942
  - lib/tasks/migrations/migrate_user_addresses.rake
943
943
  - lib/tasks/migrations/rename_gateways.rake
944
944
  - lib/tasks/order_capturing.rake
945
+ - lib/tasks/solidus/check_orders_with_invalid_email.rake
945
946
  - lib/tasks/upgrade.rake
946
947
  - solidus_core.gemspec
947
948
  - vendor/assets/javascripts/jquery.payment.js