Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Base#adapt_source modifies input string in-place #40

Closed
ddfreyne opened this issue Mar 11, 2013 · 1 comment
Closed

Base#adapt_source modifies input string in-place #40

ddfreyne opened this issue Mar 11, 2013 · 1 comment
Assignees

Comments

@ddfreyne
Copy link

@ddfreyne ddfreyne commented Mar 11, 2013

Kramdown::Parser::Base#adapt_source modifies the encoding of the input string in-place (source). I don’t believe it should; input arguments should not be touched.

Possible fix: replace

source.encode!('UTF-8')

with

source = source.encode('UTF-8')

(Related nanoc issues: nanoc/nanoc#276, nanoc/nanoc#277)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants