umbrellio-utils 0.7.3 → 0.7.4

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: 98131475f6f02d086ddd897b81950bfb2747a9f9791d11a02e10854595731095
4
- data.tar.gz: 878a13eda629ee1f8b1a98295cbe62f28432d287157e5b4d8544a9e96f6104af
3
+ metadata.gz: 0fbbcbcfd7e518b7673e46222b16b7b1bd34043e6ce41daeab68be72061a0c02
4
+ data.tar.gz: 77c3e024673156610281bcb81cbdaf25ec86e1034ab32c02975f0afa39ef7f06
5
5
  SHA512:
6
- metadata.gz: '089e33e5ed1b28c0f3dd2436c67504a217c2f0a6eb408aba9e85317f19492867c43acb2bb3dfddeee9033e39c4a922d22e897256648fe17b81412ff74f6fa06f'
7
- data.tar.gz: 7bc11b43a216779e44c2cd1b799932caed2a14538ca4c1d4706c9a1762b304660cbb1aa0523951e5cabef32ba11a3025e7996ef8fd9119d0a08a98d1fce7a224
6
+ metadata.gz: 79ed5bc2a2c4c1c1271fb7f9ed026b7993d22d426e11a25dc6af9c0f950d24f10a92cbd4820a84704f49c4af42696a8382bb9d5d3354684d2565509dd8cc356e
7
+ data.tar.gz: 2d38414441ef3aeceab73d7089c2656dcffaf78c4a9f4142f9ce091ad058a0a816882b0a1e0b1d99388822100e1042489e68c689f14c75090b37e40144a2dc0d
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- umbrellio-utils (0.7.3)
4
+ umbrellio-utils (0.7.4)
5
5
  memery (~> 1)
6
6
 
7
7
  GEM
@@ -4,8 +4,9 @@ module UmbrellioUtils
4
4
  class RequestWrapper
5
5
  include Memery
6
6
 
7
- def initialize(request)
7
+ def initialize(request, remove_xml_attributes: true)
8
8
  self.request = request
9
+ self.remove_xml_attributes = remove_xml_attributes
9
10
  end
10
11
 
11
12
  memoize def params
@@ -50,14 +51,14 @@ module UmbrellioUtils
50
51
 
51
52
  private
52
53
 
53
- attr_accessor :request
54
+ attr_accessor :request, :remove_xml_attributes
54
55
 
55
56
  def parse_params
56
57
  case request.media_type
57
58
  when "application/json", /\+json\z/
58
59
  Parsing.safely_parse_json(body)
59
60
  when "application/xml"
60
- Parsing.parse_xml(body)
61
+ Parsing.parse_xml(body, remove_attributes: remove_xml_attributes)
61
62
  else
62
63
  request.get? ? request.GET : request.POST
63
64
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module UmbrellioUtils
4
- VERSION = "0.7.3"
4
+ VERSION = "0.7.4"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: umbrellio-utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.3
4
+ version: 0.7.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - JustAnotherDude
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-09-12 00:00:00.000000000 Z
11
+ date: 2023-12-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: memery
@@ -86,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
86
86
  - !ruby/object:Gem::Version
87
87
  version: '0'
88
88
  requirements: []
89
- rubygems_version: 3.4.19
89
+ rubygems_version: 3.4.21
90
90
  signing_key:
91
91
  specification_version: 4
92
92
  summary: A set of utilities that speed up development