mail-iso-2022-jp 1.0.6 → 1.0.7

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -107,10 +107,10 @@ Remarks
107
107
  -------
108
108
 
109
109
  * Wave dashes (U+301C) are replaced with fullwidth tildes (U+FF5E) before converted to iso-2022-jp.
110
- * Special characters such as `髙` or `﨑` are handled correctly.
110
+ * Special characters such as `髙` or `﨑` can't be handled correctly when they are found in the mail headers. This is a TODO.
111
111
 
112
112
  * 波ダッシュ(U+301C)は、iso-2022-jpへの変換前に全角チルダ(U+FF5E)で置き換えられます。
113
- * `髙` や `﨑` 等のIBM拡張文字も扱えます。
113
+ * `髙` や `﨑` といった特殊文字がメールヘッダにある場合は、正しく扱えません。これはTODO項目です。
114
114
 
115
115
 
116
116
  References
@@ -40,7 +40,7 @@ module Mail
40
40
  def initialize_with_iso_2022_jp_encoding(value = nil, charset = 'utf-8')
41
41
  if charset.to_s.downcase == 'iso-2022-jp'
42
42
  value.gsub!(/#{WAVE_DASH}/, FULLWIDTH_TILDE)
43
- value = NKF.nkf('--cp932 -j', value)
43
+ value = NKF.nkf('--cp51932 -j', value)
44
44
  value.force_encoding('ascii-8bit') if RUBY_VERSION >= '1.9'
45
45
  value = b_value_encode(value)
46
46
  value.force_encoding('ascii-8bit') if RUBY_VERSION >= '1.9'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mail-iso-2022-jp
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -14,7 +14,7 @@ date: 2011-11-20 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: mail
17
- requirement: &18047620 !ruby/object:Gem::Requirement
17
+ requirement: &21574180 !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
20
  - - ! '>='
@@ -22,7 +22,7 @@ dependencies:
22
22
  version: 2.2.5
23
23
  type: :runtime
24
24
  prerelease: false
25
- version_requirements: *18047620
25
+ version_requirements: *21574180
26
26
  description: A patch that provides 'mail' gem with iso-2022-jp conversion capability.
27
27
  email: hermes@oiax.jp
28
28
  executables: []