kelredd-useful 0.1.8.2 → 0.1.8.3
Sign up to get free protection for your applications and to get access to all the features.
@@ -23,7 +23,7 @@ module Useful
|
|
23
23
|
if first_letter_in_uppercase
|
24
24
|
lower_case_and_underscored_word.to_s.gsub(/\/(.?)/) { "::#{$1.upcase}" }.gsub(/(?:^|_)(.)/) { $1.upcase }
|
25
25
|
else
|
26
|
-
lower_case_and_underscored_word.
|
26
|
+
lower_case_and_underscored_word.[0..0].downcase + camelize(lower_case_and_underscored_word)[1..-1]
|
27
27
|
end
|
28
28
|
end
|
29
29
|
|
@@ -23,7 +23,7 @@ module Sinatra
|
|
23
23
|
# EX : image_tag 'logo.jpg'
|
24
24
|
# => <img src="images/logo.jpg" />
|
25
25
|
def image_tag(src,options={})
|
26
|
-
options[:src] = ['/'].include?(src
|
26
|
+
options[:src] = ['/'].include?(src[0..0]) ? src : "/images/#{src}"
|
27
27
|
tag(:img, options)
|
28
28
|
end
|
29
29
|
|
data/lib/useful/version.rb
CHANGED