lib/loggability/loghost.rb in loggability-0.10.1 vs lib/loggability/loghost.rb in loggability-0.11.0
- old
+ new
@@ -33,8 +33,15 @@
def logger=( newlogger )
@logger = Loggability::Logger( newlogger )
end
alias_method :log=, :logger=
+
+ ### Register subclasses of log hosts as their own log hosts.
+ def inherited( subclass )
+ super
+ Loggability.register_loghost( subclass )
+ end
+
end # module Loggability::LogHost