dominate 0.7.1 → 0.7.2

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: a416f2d905396672593ad684ca4ffb6b0100cbfe
4
- data.tar.gz: 60c5a2c952d39a88f58428718135aa051e3f44bb
3
+ metadata.gz: a16990917e609403b3bf9558f8c9149072c40af3
4
+ data.tar.gz: 81eea62bec643eccc15c88716ddb61ed5d618957
5
5
  SHA512:
6
- metadata.gz: 32ceb35b0fc72c89a033dfa78ad133ae8af9ccbeb25ebd0f6dacbfc2648c37a88b46d6c7470c58375f690f5e4361ff1b2a753bb117dfc374899ed1c616db20a2
7
- data.tar.gz: f3f794b9d0e475b3194b5fb735324ad6c7ef3c5b6a2893654f5cbc2858cd5ede5c289cec7c42586eeed3f000b8488d5ca339a16d9e391b12563642c2f2814ef3
6
+ metadata.gz: 723043df5c8f4103c696f28db2ffe505af90341f491663195fa6a8886512b59ee6c6c90b4c5afc8fd96c0fee84b81655b0730f11ca474d81f07c5353446295ed
7
+ data.tar.gz: 03553843e1148fed8043d65640aaf4d60e4cafc077c0123078d17c8457cb226a9c377e1ae2bdeab7c8c4a7db7473b0adc956bc1d10f2d0439e350cb2a5e30701
@@ -1,3 +1,3 @@
1
1
  module Dominate
2
- VERSION = "0.7.1"
2
+ VERSION = "0.7.2"
3
3
  end
@@ -106,9 +106,9 @@ module Dominate
106
106
 
107
107
  def trigger widget_event, data = {}
108
108
  data = data.to_h
109
- widget_name = data.delete(:for) || name
109
+ widget_name = data.has_key?(:for) ? data.delete(:for) : name
110
110
 
111
- event.trigger widget_name.to_sym, widget_event, data.to_h
111
+ event.trigger widget_name, widget_event, data.to_h
112
112
  # threads = []
113
113
  #
114
114
  # req.env[:loaded_widgets].each do |n, w|
@@ -127,7 +127,7 @@ module Dominate
127
127
  if class_events = self.class.events
128
128
  class_events.each do |class_event, opts|
129
129
  if class_event.to_s == widget_event.to_s && (
130
- widget_name.to_s == name.to_s or
130
+ (widget_name.to_s == name.to_s && !opts.has_key?(:for)) or
131
131
  opts[:for].to_s == widget_name.to_s
132
132
  )
133
133
  if not opts[:with]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dominate
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - cj