arb-dict 0.2.3 → 0.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/arb-dict +1 -0
- data/lib/arb/dict.rb +4 -4
- data/lib/arb/dict/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: f619ff315f143f075fdd5e975a79e051eb678bd5
|
4
|
+
data.tar.gz: eb0e268deae4a9fd6d0c6920b5692df8f2d048c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 544303a78a66ebaeefaea6955fbf8bea3e726ead4b933d8e4b5d7bd32ff942a0869f8ae24a2bce45808b26093320ae0b6c0a012600a07fbd083752fd15509ccb
|
7
|
+
data.tar.gz: 9521c7a613d54e163c84d0f8f1873db2457ee5e7b69d36a40d8f5c23fe37870078ded8b9f3d2ac65f745a0c86ac6d4886c8c146a459bf48b6dfd25cdc9377b23
|
data/bin/arb-dict
CHANGED
data/lib/arb/dict.rb
CHANGED
@@ -9,12 +9,12 @@ module Arb
|
|
9
9
|
tmp_hash = JSON.parse(open("http://dict.youdao.com/jsonresult?q=#{URI.encode(entity)}&type=1").read)
|
10
10
|
main_hash = { entity: entity }
|
11
11
|
if entity.ascii_only?
|
12
|
-
main_hash[:phonetic_us]=strict_value(tmp_hash['sm'],
|
13
|
-
main_hash[:phonetic_uk]=strict_value(tmp_hash['uksm'],
|
12
|
+
main_hash[:phonetic_us]=strict_value(tmp_hash['sm'],nil)
|
13
|
+
main_hash[:phonetic_uk]=strict_value(tmp_hash['uksm'],nil)
|
14
14
|
else
|
15
|
-
main_hash[:phonetic]=strict_value(tmp_hash['sm'],
|
15
|
+
main_hash[:phonetic]=strict_value(tmp_hash['sm'],nil)
|
16
16
|
end
|
17
|
-
main_hash[:translation]=strict_value(tmp_hash['basic'],
|
17
|
+
main_hash[:translation]=strict_value(tmp_hash['basic'],nil)
|
18
18
|
main_hash
|
19
19
|
end
|
20
20
|
private
|
data/lib/arb/dict/version.rb
CHANGED