activeldap 6.1.0 → 7.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/doc/text/news.md +14 -0
- data/lib/active_ldap/attribute_methods.rb +11 -2
- data/lib/active_ldap/base.rb +7 -1
- data/lib/active_ldap/log_subscriber.rb +11 -3
- data/lib/active_ldap/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 46d1a0c273dff5757de13f0a8379278794a5b4f2c89a1ff60e9a7e97dd0f8867
|
4
|
+
data.tar.gz: ec7c5e06e7e75d46a55b5ea163f56fb85d833e82eb2d66b2f3fb9bc07ce7c7ce
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7b1b5e88e3d2bf65bec620b15909f882cb3d4a386b0a482f7de18e88934cce1750ddc72175033b73accbb9a83f41e4ab947c9ffe4903abbca35ec1422c612978
|
7
|
+
data.tar.gz: dbf5a8751b7cd7235c9211738b50bb60a1450290c630a8a6a9a5faea2d3cac1ff8897cfb11ef98d5b87cc2bdda2128642d417638580c09659185b703a7efd0a5
|
data/Gemfile
CHANGED
data/doc/text/news.md
CHANGED
@@ -1,5 +1,19 @@
|
|
1
1
|
# News
|
2
2
|
|
3
|
+
## 7.0.0: 2024-02-23 {#release-6-1-1}
|
4
|
+
|
5
|
+
### Improvements
|
6
|
+
|
7
|
+
* Added support for Active Model 7.
|
8
|
+
* GH-193
|
9
|
+
* GH-194
|
10
|
+
* GH-195
|
11
|
+
* Patch by J-Verz.
|
12
|
+
|
13
|
+
### Thanks
|
14
|
+
|
15
|
+
* J-Verz
|
16
|
+
|
3
17
|
## 6.1.0: 2020-12-24 {#release-6-1-0}
|
4
18
|
|
5
19
|
### Improvements
|
@@ -7,8 +7,17 @@ module ActiveLdap
|
|
7
7
|
target_names = entry_attribute.all_names
|
8
8
|
target_names -= ['objectClass', 'objectClass'.underscore]
|
9
9
|
super + target_names.uniq.collect do |attr|
|
10
|
-
|
11
|
-
|
10
|
+
method_patterns =
|
11
|
+
if self.class.respond_to?(:attribute_method_patterns)
|
12
|
+
# Support for ActiveModel >= 7.1.0
|
13
|
+
self.class.attribute_method_patterns
|
14
|
+
else
|
15
|
+
# Support for ActiveModel < 7.1.0
|
16
|
+
self.class.attribute_method_matchers
|
17
|
+
end
|
18
|
+
|
19
|
+
method_patterns.collect do |pattern|
|
20
|
+
pattern.method_name(attr).to_sym
|
12
21
|
end
|
13
22
|
end.flatten
|
14
23
|
end
|
data/lib/active_ldap/base.rb
CHANGED
@@ -1036,7 +1036,13 @@ module ActiveLdap
|
|
1036
1036
|
if value.is_a?(String) and value.length > 50
|
1037
1037
|
"#{value[0, 50]}...".inspect
|
1038
1038
|
elsif value.is_a?(Date) || value.is_a?(Time)
|
1039
|
-
|
1039
|
+
if value.respond_to?(:to_fs)
|
1040
|
+
# Support for Rails >= 7.0
|
1041
|
+
value.to_fs(:db)
|
1042
|
+
else
|
1043
|
+
# Support for Rails < 7.0
|
1044
|
+
value.to_s(:db)
|
1045
|
+
end
|
1040
1046
|
else
|
1041
1047
|
value.inspect
|
1042
1048
|
end
|
@@ -29,11 +29,19 @@ module ActiveLdap
|
|
29
29
|
name = 'LDAP: %s (%.1fms)' % [label, event.duration]
|
30
30
|
inspected_info = info.inspect
|
31
31
|
|
32
|
+
formatting_options =
|
33
|
+
if ActiveSupport.version >= Gem::Version.new('7.1.0')
|
34
|
+
{ bold: true }
|
35
|
+
else
|
36
|
+
# Fallback for ActiveSupport < 7.1.0
|
37
|
+
true
|
38
|
+
end
|
39
|
+
|
32
40
|
if odd?
|
33
|
-
name = color(name, CYAN,
|
34
|
-
inspected_info = color(inspected_info, nil,
|
41
|
+
name = color(name, CYAN, formatting_options)
|
42
|
+
inspected_info = color(inspected_info, nil, formatting_options)
|
35
43
|
else
|
36
|
-
name = color(name, MAGENTA,
|
44
|
+
name = color(name, MAGENTA, formatting_options)
|
37
45
|
end
|
38
46
|
|
39
47
|
debug " #{name} #{inspected_info}"
|
data/lib/active_ldap/version.rb
CHANGED
metadata
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activeldap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 7.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Will Drewry
|
8
8
|
- Kouhei Sutou
|
9
|
-
autorequire:
|
9
|
+
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2024-02-23 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activemodel
|
@@ -330,7 +330,7 @@ licenses:
|
|
330
330
|
- Ruby's
|
331
331
|
- GPLv2 or later
|
332
332
|
metadata: {}
|
333
|
-
post_install_message:
|
333
|
+
post_install_message:
|
334
334
|
rdoc_options: []
|
335
335
|
require_paths:
|
336
336
|
- lib
|
@@ -345,8 +345,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
345
345
|
- !ruby/object:Gem::Version
|
346
346
|
version: '0'
|
347
347
|
requirements: []
|
348
|
-
rubygems_version: 3.
|
349
|
-
signing_key:
|
348
|
+
rubygems_version: 3.5.1
|
349
|
+
signing_key:
|
350
350
|
specification_version: 4
|
351
351
|
summary: ActiveLdap is a object-oriented API to LDAP
|
352
352
|
test_files:
|