summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiklós Fazekas <mfazekas@szemafor.com>2020-02-11 06:37:25 +0100
committerGitHub <noreply@github.com>2020-02-11 06:37:25 +0100
commit71634cbb0fbc15abb989f8652a866d715012f8e2 (patch)
treef5dfcad5841f749c6e728f80fa555128281985aa
parent4d2142cc5bd0889cd5465dfd371ef7a521376835 (diff)
parent0c7d233f6e3c860623d410e1337640d66539980f (diff)
downloadnet-ssh-71634cbb0fbc15abb989f8652a866d715012f8e2.tar.gz
Merge pull request #733 from hirura/fix-loggable_facility_to_use_to_s_method_instead_of_name_method_for_self_class
Fix Loggable to use to_s method instead of name method for self.class
-rw-r--r--lib/net/ssh/loggable.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/net/ssh/loggable.rb b/lib/net/ssh/loggable.rb
index 50b26bf..b9df4d5 100644
--- a/lib/net/ssh/loggable.rb
+++ b/lib/net/ssh/loggable.rb
@@ -56,8 +56,8 @@ module Net
# originates. It defaults to the name of class with the object_id
# appended.
def facility
- @facility ||= self.class.name.gsub(/::/, ".").gsub(/([a-z])([A-Z])/, "\\1_\\2").downcase + "[%x]" % object_id
+ @facility ||= self.class.to_s.gsub(/::/, ".").gsub(/([a-z])([A-Z])/, "\\1_\\2").downcase + "[%x]" % object_id
end
end
end
-end \ No newline at end of file
+end