Linux tsuru-no-tsurugi 5.15.0-186-generic #196-Ubuntu SMP Sat Jun 20 16:09:34 UTC 2026 x86_64
Apache/2.4.52 (Ubuntu)
Server IP : 192.168.0.18 & Your IP : 216.73.216.68
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
lib /
ruby /
3.0.0 /
did_you_mean /
spell_checkers /
Delete
Unzip
Name
Size
Permission
Date
Action
name_error_checkers
[ DIR ]
drwxr-xr-x
2026-07-06 06:50
key_error_checker.rb
474
B
-rw-r--r--
2021-07-07 19:08
method_name_checker.rb
1.81
KB
-rw-r--r--
2021-07-07 19:08
name_error_checkers.rb
567
B
-rw-r--r--
2021-07-07 19:08
null_checker.rb
104
B
-rw-r--r--
2021-07-07 19:08
require_path_checker.rb
1.09
KB
-rw-r--r--
2021-07-07 19:08
Save
Rename
# frozen-string-literal: true require_relative "../spell_checker" require_relative "../tree_spell_checker" module DidYouMean class RequirePathChecker attr_reader :path INITIAL_LOAD_PATH = $LOAD_PATH.dup.freeze ENV_SPECIFIC_EXT = ".#{RbConfig::CONFIG["DLEXT"]}" private_constant :INITIAL_LOAD_PATH, :ENV_SPECIFIC_EXT def self.requireables @requireables ||= INITIAL_LOAD_PATH .flat_map {|path| Dir.glob("**/???*{.rb,#{ENV_SPECIFIC_EXT}}", base: path) } .map {|path| path.chomp!(".rb") || path.chomp!(ENV_SPECIFIC_EXT) } end def initialize(exception) @path = exception.path end def corrections @corrections ||= begin threshold = path.size * 2 dictionary = self.class.requireables.reject {|str| str.size >= threshold } spell_checker = path.include?("/") ? TreeSpellChecker : SpellChecker spell_checker.new(dictionary: dictionary).correct(path).uniq end end end end