blazer-plus 0.1.1 → 0.1.3

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: b2315dcdf5094e74fd5c1cba5a583eb504e56d4cb917900a02b0fa423f7659ea
4
- data.tar.gz: 444ef92d9814ec8d65bcf8d09eb60d2b651f8d59330e859903abd3b423a290a9
3
+ metadata.gz: 805f826bcf95f92d5821f6593ea2eaa986908917cb0237d58356174b1238babd
4
+ data.tar.gz: 162d43a0c2fd06b8bad04a258dfdeea3c0327525639c13608d167995ab8c4d63
5
5
  SHA512:
6
- metadata.gz: 3b54a5de1403b8917e4be8de161fbfc4b8e2160326b15d61d40bb7688edc2f8c07ef72e1645d647829a2c946da90b783c2ed5cfeba508c8ae3ab52a7dbb1f111
7
- data.tar.gz: dce7ffa42dcac73d063951c5b6357132963742dc9d1c0e37f8f6d94dafd11a21f7aadec4bb8518a8aa5e340b755298c3e69b44806c44f27be41560c15357a40f
6
+ metadata.gz: f66dc36470c764de34b4e0560a9090bbd4c47cf0ffa10ed7b7102d474fa0221ad8240fb36533990bd59a7529217775ed373f36d100130154d0f9addf4b9e923b
7
+ data.tar.gz: 5c86241409306b07974146d78351b317672f0107a2f8158339dd3e3d49705b58928cec71565b93c481437a895378dbf81517c61ca9e45bccd9e198120cd52b3b
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.1.3] - 2026-11-24
4
+
5
+ - Fix row_limit not applied with blazer 3.5+ (results are fetched without an Accept header)
6
+
3
7
  ## [0.1.0] - 2023-11-09
4
8
 
5
9
  - Initial release
@@ -18,12 +18,12 @@ module Blazer
18
18
  "\xEF\xBB\xBF#{super}"
19
19
  end
20
20
 
21
- # NOTE: Support row_limit setting for HTML
21
+ # NOTE: Support row_limit setting.
22
+ # Don't check `request.format == :html`: blazer 3.5+ fetches results without an
23
+ # Accept header, so the format is */*. Only CSV download should be unlimited.
22
24
  def render_run
23
25
  row_limit = Blazer.settings.fetch('row_limit', DEFAULT_ROW_LIMIT)
24
- if request.format == :html && row_limit
25
- @row_limit ||= row_limit
26
- end
26
+ @row_limit ||= row_limit if row_limit && !request.format.csv?
27
27
 
28
28
  super
29
29
  end
@@ -6,8 +6,12 @@ require_relative 'queries_controller'
6
6
  module Blazer
7
7
  module Plus
8
8
  class Railtie < ::Rails::Railtie
9
- initializer :initialize_blazer_plus, after: :load_config_initializers do
10
- Rails.application.reloader.to_prepare do
9
+ # Some gems (for example, action_policy) extend ActionController::Base in their to_prepare blocks and
10
+ # the blocks must be called before subclasses of ActionController::Base are loaded.
11
+ # So following to_prepare block must be called after other gems' to_prepare blocks.
12
+ # `before: :add_to_prepare_blocks` enforces the order of them.
13
+ initializer :initialize_blazer_plus, before: :add_to_prepare_blocks do
14
+ Rails.application.config.to_prepare do
11
15
  ::Blazer::QueriesController.prepend(::Blazer::Plus::QueriesController) if ::Blazer::Plus.enabled
12
16
  end
13
17
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Blazer
4
4
  module Plus
5
- VERSION = '0.1.1'
5
+ VERSION = '0.1.3'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: blazer-plus
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - aki77
8
- autorequire:
9
8
  bindir: exe
10
9
  cert_chain: []
11
- date: 2023-11-09 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: blazer
@@ -67,7 +66,6 @@ metadata:
67
66
  source_code_uri: https://github.com/SonicGarden/blazer-plus/
68
67
  changelog_uri: https://github.com/SonicGarden/blazer-plus/releases
69
68
  rubygems_mfa_required: 'true'
70
- post_install_message:
71
69
  rdoc_options: []
72
70
  require_paths:
73
71
  - lib
@@ -82,8 +80,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
82
80
  - !ruby/object:Gem::Version
83
81
  version: '0'
84
82
  requirements: []
85
- rubygems_version: 3.4.10
86
- signing_key:
83
+ rubygems_version: 4.0.20
87
84
  specification_version: 4
88
85
  summary: Feature extension for safely using Blazer
89
86
  test_files: []