dynarex-blog 0.3.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/dynarex-blog.rb +2 -2
- metadata +1 -1
data/lib/dynarex-blog.rb
CHANGED
|
@@ -16,7 +16,7 @@ class DynarexBlog
|
|
|
16
16
|
@file_path = file_path[/\/$/] ? file_path : file_path + '/'
|
|
17
17
|
if File.exists? (@file_path + 'index.xml') then open(@file_path) else fresh_start() end
|
|
18
18
|
@current_lookup = '_entry_lookup.xml'
|
|
19
|
-
@hc_lookup = HashCache.new(size:
|
|
19
|
+
@hc_lookup = HashCache.new(size: 15)
|
|
20
20
|
@hc_result = HashCache.new(size: 5)
|
|
21
21
|
@hc_entry_file = HashCache.new(size: 5)
|
|
22
22
|
super()
|
|
@@ -156,7 +156,7 @@ class DynarexBlog
|
|
|
156
156
|
|
|
157
157
|
temp_doc = Document.new '<root/>'
|
|
158
158
|
a.map{|x| x.text('file').to_s}.uniq.each do |file|
|
|
159
|
-
doc_entryx = Document.new(
|
|
159
|
+
doc_entryx = Document.new( @hc_entry_file.read(file) {File.open(@file_path + file,'r').read})
|
|
160
160
|
XPath.each(doc_entryx.root,'records/entry') do |entry|
|
|
161
161
|
temp_doc.root.add entry
|
|
162
162
|
end
|