miteru 2.2.3 → 2.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ef0f7be4745e537ba70aa893d53cc2feba75aa2216181fedc70a90a1ca61d61c
4
- data.tar.gz: 8199f226be26efa86e0bb01baa7ee1233e2bbb1476d32967359d090a3e01312a
3
+ metadata.gz: a604d9ad1201fb7cd6584ff8bbdfc4d48634a89e1f72ff0fb4735407dd4b1a45
4
+ data.tar.gz: a947966c3b6f07b6da217fd093ab6d842c0e55dc4db960bb7475344d11f71f54
5
5
  SHA512:
6
- metadata.gz: ff0cb9a02102696c4fd22ff41894be87c6fa14415fac141bb07915d70920963d2229f5a7483133417c1fc4f162bdc4d7fadab24d6972d2c50cf60b8b04d650ed
7
- data.tar.gz: f772d4fa43d0659532752c187b7613887a41cf0b58e3b996530d6aea84ac9be1ed21b7fbb0385423f677a8f3c81d8cf61d4f1461f66e9eec9718ce92d8cec28f
6
+ metadata.gz: f80bf7a2d2a78cfa2da9b699e709d8b29a38a486a50df992542ef5d22d0a18aaa20779f591851db2f0bd5378f6e9e4841e8053899b73c304f7d35807b6f37621
7
+ data.tar.gz: 4aa5a130dbec8eb692c832140af1d1ad5a42350171b03ea7257578484e4affa149c47e7a2642be7177d71330cba346928849a3de78a41c8adf93eeecd5d91fef
@@ -0,0 +1,7 @@
1
+ require "active_support/number_helper"
2
+
3
+ module Miteru
4
+ module Helpers
5
+ extend ActiveSupport::NumberHelper
6
+ end
7
+ end
data/lib/miteru/kit.rb CHANGED
@@ -75,7 +75,7 @@ module Miteru
75
75
  def filename_with_size
76
76
  return filename unless filesize
77
77
 
78
- "#{filename} (#{filesize.kilobytes}KB)"
78
+ "#{filename} (#{Helpers.number_to_human_size(filesize)})"
79
79
  end
80
80
 
81
81
  def id
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Miteru
4
- VERSION = "2.2.3"
4
+ VERSION = "2.2.4"
5
5
  end
data/lib/miteru.rb CHANGED
@@ -33,6 +33,9 @@ require "miteru/concerns/database_connectable"
33
33
  require "miteru/concerns/error_unwrappable"
34
34
  require "miteru/concerns/url_truncatable"
35
35
 
36
+ # Helpers
37
+ require "miteru/helpers"
38
+
36
39
  # Core classes
37
40
  require "miteru/service"
38
41
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: miteru
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.3
4
+ version: 2.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Manabu Niseki
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-03-03 00:00:00.000000000 Z
11
+ date: 2024-03-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -601,6 +601,7 @@ files:
601
601
  - lib/miteru/feeds/phishing_database.rb
602
602
  - lib/miteru/feeds/urlscan.rb
603
603
  - lib/miteru/feeds/urlscan_pro.rb
604
+ - lib/miteru/helpers.rb
604
605
  - lib/miteru/http.rb
605
606
  - lib/miteru/kit.rb
606
607
  - lib/miteru/mixin.rb