paloma 1.2.1 → 1.2.2

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/README.md CHANGED
@@ -8,6 +8,7 @@ Advantages
8
8
  * Javascript files are organized per controller just like app/views folder of Rails.
9
9
  * Javascript file per controller's action.
10
10
  * The ability to choose what specific javascript code to run on a specific action.
11
+ * Easily make ruby variables available on your javascript files.
11
12
 
12
13
  Quick Example
13
14
  -
@@ -25,13 +25,16 @@ module Paloma
25
25
  :locals => {:callbacks => session[:callbacks]})
26
26
 
27
27
  before_body_end_index = response_body[0].rindex('</body>')
28
- before_body_end_content = response_body[0][0, before_body_end_index].html_safe
29
- after_body_end_content = response_body[0][before_body_end_index..-1].html_safe
30
28
 
31
- response_body[0] = before_body_end_content + paloma_txt + after_body_end_content
32
-
33
- response.body = response_body[0]
34
- clear_callbacks
29
+ if before_body_end_index.present?
30
+ before_body_end_content = response_body[0][0, before_body_end_index].html_safe
31
+ after_body_end_content = response_body[0][before_body_end_index..-1].html_safe
32
+
33
+ response_body[0] = before_body_end_content + paloma_txt + after_body_end_content
34
+
35
+ response.body = response_body[0]
36
+ clear_callbacks
37
+ end
35
38
  end
36
39
 
37
40
 
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'paloma'
3
- s.version = '1.2.1'
3
+ s.version = '1.2.2'
4
4
  s.summary = "a sexy way to organize javascript files using Rails` asset pipeline"
5
5
  s.description = "a sexy way to organize javascript files using Rails` asset pipeline"
6
6
  s.authors = ["Karl Paragua", "Bia Esmero"]
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: 1.2.1
4
+ version: 1.2.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: