lib/ayadn/post.rb in ayadn-1.7.4 vs lib/ayadn/post.rb in ayadn-1.7.5

- old
+ new

@@ -104,9 +104,13 @@ end post end def post_size(post) # works on a string + words = post.split(" ") + result = [] + words.each { |word| result << get_markdown_text(word) } + post = result.join(" ") size, max_size = post.length, Settings.config[:post_max_length] if size < 1 abort(error_text_empty) elsif size > max_size Errors.warn "Canceled: too long (#{size - max_size}chars)"