projects
/
rails.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
461e39f
)
Only call force_encoding on ruby 1.9
author
Tom Hughes
<tom@compton.nu>
Mon, 12 Nov 2012 20:19:07 +0000
(20:19 +0000)
committer
Tom Hughes
<tom@compton.nu>
Mon, 12 Nov 2012 20:19:07 +0000
(20:19 +0000)
lib/potlatch.rb
patch
|
blob
|
history
diff --git
a/lib/potlatch.rb
b/lib/potlatch.rb
index 35a60dfbb6b2d2757d7b2a24d29842e32077c4ec..359492fa7f19d573d1e03b96d435977d6ebe9007 100644
(file)
--- a/
lib/potlatch.rb
+++ b/
lib/potlatch.rb
@@
-107,7
+107,7
@@
module Potlatch
# Encode string with two-byte length
def self.encodestring(n)
- n=n.dup.force_encoding("ASCII-8BIT")
+ n=n.dup.force_encoding("ASCII-8BIT")
if n.respond_to?("force_encoding")
a,b=n.size.divmod(256)
a.chr+b.chr+n
end