Flowdock
number_to_human_size(size) public

Returns a formatted-for-humans file size.

Examples:

  human_size(123)          => 123 Bytes
  human_size(1234)         => 1.2 KB
  human_size(12345)        => 12.1 KB
  human_size(1234567)      => 1.2 MB
  human_size(1234567890)   => 1.1 GB
Show source
Register or log in to add new notes.