lownode 0.5.10 → 0.5.11
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 +4 -4
- data/lib/templates/renderer.rb +2 -2
- data/lib/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: bc3a58ddd19cb2e435d07bf036eb2cb5bb15bfb9d1dcde322e8f343a1102a2ec
|
|
4
|
+
data.tar.gz: 25b0a07ca7d4eee5fc35a910e6edf0efbb9ca66f5c41aeef0f1d494e653566c1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: de73cf7e2a2d46f544b7096a9a67d0eac5b32a01fae936fd72dc8f2d6332d273ce12ab46468f0d9a034f110734e182283a2564d83fc37d819184e44a06015efc
|
|
7
|
+
data.tar.gz: 1b9d857d6fae49e2d08bc5fb79df9662f9c135493b1974ef71976819c32f85aad1bf57c6b5ba063471015c95b6285002ba85d93b49112aa09110636c9bb2b108
|
data/lib/templates/renderer.rb
CHANGED
|
@@ -108,9 +108,9 @@ module Low
|
|
|
108
108
|
end
|
|
109
109
|
end
|
|
110
110
|
|
|
111
|
-
# What a template or action rendered, as HTML.
|
|
111
|
+
# What a template or action rendered, as HTML unless the node added its own content type, like text/plain.
|
|
112
112
|
def html_response_event(html:, event:, headers:)
|
|
113
|
-
headers.add('content-type', 'text/html')
|
|
113
|
+
headers.add('content-type', 'text/html') unless headers.include?('content-type')
|
|
114
114
|
response = Protocol::HTTP::Response.new('HTTP/1.1', response_status(event), headers, Protocol::HTTP::Body::Buffered.wrap(html.strip))
|
|
115
115
|
Low::Events::ResponseEvent.new(response:).tap(&:branch)
|
|
116
116
|
end
|
data/lib/version.rb
CHANGED