markdiff 0.5.3 → 0.5.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: dc5276d66e3a92675f67df003904b6af4e11e07a
4
- data.tar.gz: 6f87e774e011a747c1d0ca04d3c03aa254ace843
3
+ metadata.gz: 253f738465580e885b9b7724ed900dbf171c90e3
4
+ data.tar.gz: b9b941d9fc3b4169e309750ee952698f40d4c60d
5
5
  SHA512:
6
- metadata.gz: 0875b2ed67d13d30eb534b9c791a2157f99da480815b8c2f92ab039defa67fdb70afcf2d1bafb78862771c38db7118df5e6ffea4cfe77e051589824eff370d91
7
- data.tar.gz: 04d03b94cd96f994a7e752988ce33ba0117231ff7269a2efc17c6403c59e97d38899968a589d2e9d7ee56b8a7d0ee2a117837a875e990fcf51f9b8839c05bbe6
6
+ metadata.gz: f3cc15598bf1ff8a2915a05b78fb9e0fce660edd5557de5f023353c1a355c5fa353b40beeb6c0caf4b81918aeea560b302e02c8f6c371c7f5d4a6810e482c9d8
7
+ data.tar.gz: 662a972f514dce5543a8b1f2a0107a8e05411751bef87bc7bef63c63b97ac6831d65fd1620b57534192b6aa5c1e9716ce52c989566df69399f4ddb59cfab2757
@@ -1,3 +1,6 @@
1
+ ## 0.5.4
2
+ - Fix bug on patch operations order
3
+
1
4
  ## 0.5.3
2
5
  - Fix bug on comparing nodes
3
6
 
@@ -14,7 +14,7 @@ module Markdiff
14
14
  # @param [Nokogiri::XML::Node] node
15
15
  # @return [Nokogiri::XML::Node] Converted node
16
16
  def apply_patch(operations, node)
17
- operations.sort_by(&:priority).reverse.each do |operation|
17
+ operations.sort_by {|operation| -operation.priority }.each do |operation|
18
18
  case operation
19
19
  when ::Markdiff::Operations::AddChildOperation
20
20
  operation.target_node.add_child(operation.inserted_node)
@@ -1,3 +1,3 @@
1
1
  module Markdiff
2
- VERSION = "0.5.3"
2
+ VERSION = "0.5.4"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: markdiff
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.3
4
+ version: 0.5.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryo Nakamura