paloma 2.0.2 → 2.0.3

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/Changelog.md CHANGED
@@ -1,6 +1,10 @@
1
1
  Changelog
2
2
  =
3
3
 
4
+ Version 2.0.3
5
+ -
6
+ * Bug Fix: prevent javascript error when callback doesn't exist.
7
+
4
8
  Version 2.0.2
5
9
  -
6
10
  * 'js(false)' will prevent Paloma from appending _callback_hook on the response.
data/paloma.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'paloma'
3
- s.version = '2.0.2'
3
+ s.version = '2.0.3'
4
4
  s.summary = "Provides an easy way to execute page-specific javascript for Rails."
5
5
  s.description = "Page-specific javascript for Rails done right"
6
6
  s.authors = ["Karl Paragua", "Bia Esmero"]
@@ -199,9 +199,11 @@ Paloma.execute = function(controller, action, params){
199
199
  var callback = Paloma.callbacks[controller];
200
200
  callbackFound = callback != undefined;
201
201
 
202
- callback = callback[action];
203
- callbackFound = callback != undefined;
204
-
202
+ if (callbackFound){
203
+ callback = callback[action];
204
+ callbackFound = callback != undefined;
205
+ }
206
+
205
207
  // Parse parameters
206
208
  params = params || {};
207
209
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: paloma
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.2
4
+ version: 2.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2013-03-25 00:00:00.000000000 Z
13
+ date: 2013-04-01 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: jquery-rails