Skip to content

Commit a0ffaa3

Browse files
committed
Test with UTF-8/Emoji content.
1 parent 0d39bff commit a0ffaa3

File tree

9 files changed

+369
-143
lines changed

9 files changed

+369
-143
lines changed

lib/nanoc/github.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ def client
2525
end
2626

2727
def decode(content)
28-
content = Base64.decode64(content)
28+
content = Base64.decode64(content).force_encoding(Encoding::UTF_8)
2929
matchdata = content.match(REGEX)
3030
metadata = matchdata ? YAML.safe_load(matchdata[:metadata], permitted_classes: [Time]) : {}
3131

test/fixtures/test_frontmatter.yml

Lines changed: 22 additions & 22 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)