dynarex 0.8.2 → 0.8.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/lib/dynarex.rb +4 -0
  2. metadata +1 -1
@@ -175,6 +175,7 @@ EOF
175
175
  end
176
176
 
177
177
  def sort_by!(&element_blk)
178
+ refresh_doc
178
179
  a = XPath.match(@doc.root, 'records/*').sort_by &element_blk
179
180
  records = XPath.first(@doc.root, 'records')
180
181
  records.parent.delete records
@@ -232,10 +233,13 @@ EOF
232
233
  end
233
234
  end
234
235
 
236
+ @doc = Document.new buffer
235
237
  buffer
236
238
 
237
239
  end
238
240
 
241
+ alias refresh_doc display_xml
242
+
239
243
  def dynarex_new(s)
240
244
  ptrn = %r((\w+)\[?([^\]]+)?\]?\/(\w+)\(([^\)]+)\))
241
245
  root_name, raw_summary, record_name, raw_fields = s.match(ptrn).captures
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dynarex
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.2
4
+ version: 0.8.3
5
5
  platform: ruby
6
6
  authors: []
7
7