shopify_app 10.0.0 → 11.0.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: 3e0d05767b5c3ee4f64bcf9e9198943956769b371d47fe4f1e4d986e8c87b776
4
- data.tar.gz: d19668b932f7e091c012f82096e12648fe61a6d2358b8c8a62c1dc18dc267eae
3
+ metadata.gz: 99e91b542c6d5f2fb530c9d259e6d32d463bb6e8d0720dd11faa009e845d2ced
4
+ data.tar.gz: '0214085b33d8ccbb7dfe929430f81b75296ac5cf201c6b9969ba0b5d78ea7351'
5
5
  SHA512:
6
- metadata.gz: 33d7d6e5c3b054a30f8d18b296ac335310561c9f383e24b8dd0a0cf0cb52f324421efa14e2ca721a1b4c48e0b63894b72d9443d37e59df155a1477eb25d6372d
7
- data.tar.gz: dec296c178ac77f2d315e7f4534dcd50c3e042ff1875299748668b10f32278ed54d6b76dec45c7a9600a97a023f6f0718ba6a022ba4fe056f8e982ab514b1305
6
+ metadata.gz: f8fb32cc915ecfeba1ee7db40f1cd3ec4e0c9b8c8bae697370248a8f6225f70504da6a3a160cdfb960426899c2d0abcbbe8f623a0771cef81c7ddb1e58ac779d
7
+ data.tar.gz: 73c4b7f0f49130ea808fd7b4c24cef408025a5fcaf89a8b29ee2c0baa0e00d0837b11ec6ecd7f35d4c57269a39e357a9d3cb7d5b55b66a76ff25b0444f503405
@@ -1,3 +1,9 @@
1
+ 11.0.0
2
+ -----
3
+
4
+ * Rename `login_url` method to `login_url_with_optional_shop` to avoid ambiguity with Rails' route helper method of the
5
+ same name (see [#585](https://github.com/Shopify/shopify_app/pull/585)).
6
+
1
7
  10.0.0
2
8
  -----
3
9
 
@@ -15,7 +15,7 @@ module ShopifyApp
15
15
  redirect_to return_address
16
16
  else
17
17
  flash[:error] = I18n.t('could_not_log_in')
18
- redirect_to login_url
18
+ redirect_to(login_url_with_optional_shop)
19
19
  end
20
20
  end
21
21
 
@@ -22,14 +22,14 @@ module ShopifyApp
22
22
  does_not_have_storage_access_url: top_level_interaction_path(
23
23
  shop: sanitized_shop_name
24
24
  ),
25
- has_storage_access_url: login_url(top_level: true),
25
+ has_storage_access_url: login_url_with_optional_shop(top_level: true),
26
26
  app_home_url: granted_storage_access_path(shop: sanitized_shop_name),
27
27
  current_shopify_domain: current_shopify_domain,
28
28
  })
29
29
  end
30
30
 
31
31
  def top_level_interaction
32
- @url = login_url(top_level: true)
32
+ @url = login_url_with_optional_shop(top_level: true)
33
33
  validate_shop
34
34
  end
35
35
 
@@ -45,7 +45,7 @@ module ShopifyApp
45
45
  def destroy
46
46
  reset_session
47
47
  flash[:notice] = I18n.t('.logged_out')
48
- redirect_to login_url
48
+ redirect_to(login_url_with_optional_shop)
49
49
  end
50
50
 
51
51
  private
@@ -110,7 +110,7 @@ module ShopifyApp
110
110
  end
111
111
 
112
112
  def authenticate_at_top_level
113
- fullpage_redirect_to login_url(top_level: true)
113
+ fullpage_redirect_to(login_url_with_optional_shop(top_level: true))
114
114
  end
115
115
 
116
116
  def authenticate_in_context?
@@ -128,14 +128,18 @@ module ShopifyApp
128
128
  end
129
129
 
130
130
  def redirect_to_request_storage_access
131
- render :request_storage_access, layout: false, locals: {
132
- does_not_have_storage_access_url: top_level_interaction_path(
133
- shop: sanitized_shop_name
134
- ),
135
- has_storage_access_url: login_url(top_level: true),
136
- app_home_url: granted_storage_access_path(shop: sanitized_shop_name),
137
- current_shopify_domain: current_shopify_domain
138
- }
131
+ render(
132
+ :request_storage_access,
133
+ layout: false,
134
+ locals: {
135
+ does_not_have_storage_access_url: top_level_interaction_path(
136
+ shop: sanitized_shop_name
137
+ ),
138
+ has_storage_access_url: login_url_with_optional_shop(top_level: true),
139
+ app_home_url: granted_storage_access_path(shop: sanitized_shop_name),
140
+ current_shopify_domain: current_shopify_domain,
141
+ }
142
+ )
139
143
  end
140
144
  end
141
145
  end
@@ -4,18 +4,19 @@ ms:
4
4
  could_not_log_in: Tidak dapat log masuk ke kedai Shopify
5
5
  invalid_shop_url: Domain kedai tidak sah
6
6
  enable_cookies_heading: Dayakan kuki dari %{app}
7
- enable_cookies_body: Anda mesti mengaktifkan kuki secara manual dalam browser ini
7
+ enable_cookies_body: Anda mesti mengaktifkan kuki secara manual dalam pelayar ini
8
8
  untuk %{app} digunakan dalam Shopify.
9
- enable_cookies_footer: Kuki membenarkan app mengesahkan anda dengan menyimpan keutamaan
10
- dan maklumat peribadi anda buat sementara waktu. Ia tamat tempoh selepas 30 hari.
9
+ enable_cookies_footer: Kuki membenarkan aplikasi mengesahkan anda dengan menyimpan
10
+ keutamaan dan maklumat peribadi anda buat sementara waktu. Ia tamat tempoh selepas
11
+ 30 hari.
11
12
  enable_cookies_action: Dayakan kuki
12
- top_level_interaction_heading: Browser anda perlu mengesahkan %{app}
13
- top_level_interaction_body: Browser anda memerlukan app seperti %{app} untuk meminta
14
- anda akses kepada kuki sebelum Shopify boleh membukanya untuk anda.
13
+ top_level_interaction_heading: Pelayar anda perlu mengesahkan %{app}
14
+ top_level_interaction_body: Pelayar anda memerlukan aplikasi seperti %{app} untuk
15
+ meminta anda akses kepada kuki sebelum Shopify boleh membukanya untuk anda.
15
16
  top_level_interaction_action: Teruskan
16
17
  request_storage_access_heading: "%{app} memerlukan akses kepada kuki"
17
- request_storage_access_body: Ini membolehkan app mengesahkan anda dengan menyimpan
18
+ request_storage_access_body: Ini membolehkan aplikasi mengesahkan anda dengan menyimpan
18
19
  maklumat peribadi anda buat sementara waktu. Klik teruskan dan benarkan kuki untuk
19
- menggunakan app.
20
+ menggunakan aplikasi.
20
21
  request_storage_access_footer: Kuki akan tamat tempoh selepas 30 hari.
21
22
  request_storage_access_action: Teruskan
@@ -47,13 +47,13 @@ module ShopifyApp
47
47
  if request.get?
48
48
  session[:return_to] = "#{request.path}?#{sanitized_params.to_query}"
49
49
  end
50
- redirect_to login_url
50
+ redirect_to(login_url_with_optional_shop)
51
51
  end
52
52
  end
53
53
 
54
54
  def close_session
55
55
  clear_shop_session
56
- redirect_to login_url
56
+ redirect_to(login_url_with_optional_shop)
57
57
  end
58
58
 
59
59
  def clear_shop_session
@@ -62,7 +62,7 @@ module ShopifyApp
62
62
  session[:shopify_user] = nil
63
63
  end
64
64
 
65
- def login_url(top_level: false)
65
+ def login_url_with_optional_shop(top_level: false)
66
66
  url = ShopifyApp.configuration.login_url
67
67
 
68
68
  query_params = login_url_params(top_level: top_level)
@@ -1,3 +1,3 @@
1
1
  module ShopifyApp
2
- VERSION = '10.0.0'.freeze
2
+ VERSION = '11.0.0'.freeze
3
3
  end
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shopify_app",
3
- "version": "10.0.0",
3
+ "version": "11.0.0",
4
4
  "lockfileVersion": 1,
5
5
  "requires": true,
6
6
  "dependencies": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shopify_app",
3
- "version": "10.0.0",
3
+ "version": "11.0.0",
4
4
  "repository": "git@github.com:Shopify/shopify_app.git",
5
5
  "author": "Shopify",
6
6
  "license": "MIT",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shopify_app
3
3
  version: !ruby/object:Gem::Version
4
- version: 10.0.0
4
+ version: 11.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shopify
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-06-26 00:00:00.000000000 Z
11
+ date: 2019-07-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: browser_sniffer