tmx_importer 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/tmx_importer.rb +1 -1
- data/lib/tmx_importer/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 879c5a494ffdf3380ca31ffc402dc031261db2bb
|
4
|
+
data.tar.gz: 09cd7465ac1b8cb93fc21edc411cba48ca20ae7d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a1e9252071f93e9a8a65f811a931e7c0aef4f914b7709d28780be54f69f543508773ac2fe379d2c67587abcaa2ce074b41bb9e1eceb628e6f61c432c5c9f0d80
|
7
|
+
data.tar.gz: 7e8e76da0b91f2ba041e75e7d86d348d6ad1fe66f03506173e0535d6e0395f9e12a0bd04df9699e4141a931bc1da1aad74498af37c54e0fdd7bba1bc4a30c7c9
|
data/lib/tmx_importer.rb
CHANGED
@@ -122,7 +122,7 @@ module TmxImporter
|
|
122
122
|
end
|
123
123
|
|
124
124
|
def write_seg(reader)
|
125
|
-
return if reader.read_string.
|
125
|
+
return if reader.read_string.nil?
|
126
126
|
text = PrettyStrings::Cleaner.new(reader.read_string.force_encoding('UTF-8')).pretty.gsub("\\","\").gsub("'",%q(\\\'))
|
127
127
|
word_count = text.gsub("\s+", ' ').split(' ').length
|
128
128
|
@doc[:seg][:vals] << [@doc[:tu][:id], @doc[:seg][:role], word_count, @doc[:seg][:lang], text, @doc[:tu][:creation_date]]
|
data/lib/tmx_importer/version.rb
CHANGED