File tree Expand file tree Collapse file tree 13 files changed +17
-19
lines changed Expand file tree Collapse file tree 13 files changed +17
-19
lines changed Original file line number Diff line number Diff line change @@ -93,8 +93,7 @@ def to_s
93
93
end
94
94
95
95
# Whether this header is acceptable in HTTP trailers.
96
- # Accept headers in trailers can provide content negotiation hints for subsequent responses.
97
- # @returns [Boolean] false, as Accept headers are generally not needed in trailers.
96
+ # @returns [Boolean] `false`, as Accept headers are generally not needed in trailers.
98
97
def self . trailer?
99
98
false
100
99
end
Original file line number Diff line number Diff line change @@ -31,13 +31,13 @@ def self.basic(username, password)
31
31
strict_base64_encoded = [ "#{ username } :#{ password } " ] . pack ( "m0" )
32
32
33
33
self . new (
34
- "Basic #{ strict_base64_encoded } "
35
- )
34
+ "Basic #{ strict_base64_encoded } "
35
+ )
36
36
end
37
37
38
38
# Whether this header is acceptable in HTTP trailers.
39
39
# Authorization credentials must not appear in trailers for security reasons.
40
- # @returns [Boolean] false, as authorization headers contain sensitive credentials .
40
+ # @returns [Boolean] ` false` , as authorization headers must be in the header of the request to be useful .
41
41
def self . trailer?
42
42
false
43
43
end
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ def upgrade?
53
53
54
54
# Whether this header is acceptable in HTTP trailers.
55
55
# Connection headers control the current connection and must not appear in trailers.
56
- # @returns [Boolean] false, as connection headers are hop-by-hop and forbidden in trailers.
56
+ # @returns [Boolean] ` false` , as connection headers are hop-by-hop and forbidden in trailers.
57
57
def self . trailer?
58
58
false
59
59
end
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ def to_h
26
26
27
27
# Whether this header is acceptable in HTTP trailers.
28
28
# Cookie headers should not appear in trailers as they contain state information needed early in processing.
29
- # @returns [Boolean] false, as cookie headers are needed during initial request processing.
29
+ # @returns [Boolean] ` false` , as cookie headers are needed during initial request processing.
30
30
def self . trailer?
31
31
false
32
32
end
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def to_time
28
28
29
29
# Whether this header is acceptable in HTTP trailers.
30
30
# Date headers can safely appear in trailers as they provide metadata about response generation.
31
- # @returns [Boolean] true, as date headers are metadata that can be computed after response generation.
31
+ # @returns [Boolean] ` true` , as date headers are metadata that can be computed after response generation.
32
32
def self . trailer?
33
33
true
34
34
end
Original file line number Diff line number Diff line change @@ -59,8 +59,8 @@ def entries
59
59
end
60
60
end
61
61
62
- # Digest headers are perfect for use as trailers since they contain
63
- # integrity hashes that can only be calculated after the entire message body is available.
62
+ # Whether this header is acceptable in HTTP trailers.
63
+ # @returns [Boolean] `true`, as digest headers contain integrity hashes that can only be calculated after the entire message body is available.
64
64
def self . trailer?
65
65
true
66
66
end
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def weak?
28
28
29
29
# Whether this header is acceptable in HTTP trailers.
30
30
# ETag headers can safely appear in trailers as they provide cache validation metadata.
31
- # @returns [Boolean] true, as ETag headers are metadata that can be computed after response generation.
31
+ # @returns [Boolean] ` true` , as ETag headers are metadata that can be computed after response generation.
32
32
def self . trailer?
33
33
true
34
34
end
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def to_s
28
28
29
29
# Whether this header is acceptable in HTTP trailers.
30
30
# This is a base class for headers with multiple values, default is to disallow in trailers.
31
- # @returns [Boolean] false, as most multiple-value headers should not appear in trailers by default.
31
+ # @returns [Boolean] ` false` , as most multiple-value headers should not appear in trailers by default.
32
32
def self . trailer?
33
33
false
34
34
end
Original file line number Diff line number Diff line change @@ -84,8 +84,8 @@ def metrics
84
84
end
85
85
end
86
86
87
- # Server-Timing headers are safe to use as trailers since they contain
88
- # performance metrics that are typically calculated during response generation.
87
+ # Whether this header is acceptable in HTTP trailers.
88
+ # @returns [Boolean] `true`, as server-timing headers contain performance metrics that are typically calculated during response generation.
89
89
def self . trailer?
90
90
true
91
91
end
Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ def to_s
42
42
43
43
# Whether this header is acceptable in HTTP trailers.
44
44
# This is a base class for comma-separated headers, default is to disallow in trailers.
45
- # @returns [Boolean] false, as most comma-separated headers should not appear in trailers by default.
45
+ # @returns [Boolean] ` false` , as most comma-separated headers should not appear in trailers by default.
46
46
def self . trailer?
47
47
false
48
48
end
You can’t perform that action at this time.
0 commit comments