only if \u0000 is included for the perf

This commit is contained in:
Sam 2015-08-19 12:30:18 +10:00
parent 431def1f52
commit 5f5d055a86

View File

@ -54,8 +54,8 @@ class PostCreator
# If we don't do this we introduce a rather risky dependency # If we don't do this we introduce a rather risky dependency
@user = user @user = user
@opts = opts || {} @opts = opts || {}
opts[:title] = pg_clean_up(opts[:title]) if opts[:title] opts[:title] = pg_clean_up(opts[:title]) if opts[:title] && opts[:title].include?("\u0000")
opts[:raw] = pg_clean_up(opts[:raw]) if opts[:raw] opts[:raw] = pg_clean_up(opts[:raw]) if opts[:raw] && opts[:raw].include?("\u0000")
@spam = false @spam = false
end end