This website works better with JavaScript.
Home
Explore
Help
Sign In
adrianshort
/
apollo
mirror of
https://github.com/adrianshort/apollo.git
Watch
1
Star
0
Fork
0
Code
Issues
0
Releases
0
Wiki
Activity
Browse Source
Trap nil object instead of string in title/description cleanup filter
#2
master
Adrian Short
12 years ago
parent
141d03ab95
commit
50c0b78fa0
1 changed files
with
4 additions
and
0 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+4
-0
app/helpers/posts_helper.rb
+ 4
- 0
app/helpers/posts_helper.rb
View File
@@ -33,6 +33,10 @@ module PostsHelper
end
def clean_description(s)
if s.nil?
return ""
end
if s.size > 137
s = s[0..136] + '...'
end
Write
Preview
Loading…
Cancel
Save