title: How to validate multiple attachments upload size?
body: <p>Hi I'm using carrierwave for uploading multiple files using its <a href="https://github.com/carrierwaveuploader/carrierwave#multiple-file-uploads" rel="nofollow">array approach</a>, but couldn't figure out how to validate the size of uploaded multiple files. I thought about something like this:</p>
  
  <pre><code>post.attachments.each do |a|
  puts a.size.to_i
  end
  </code></pre>
  
  <p>and then somehow sum it up and write a validation for the total size. Or it can also be performed on individual level.</p>