chore: remove deprecated method Colorize.on_tty_only! from Invidious LogHandler

This method has been the default since Crystal 1.17.0: https://github.com/crystal-lang/crystal/pull/15881

Is going to get deprecated when Crystal 1.21.0 is released: https://github.com/crystal-lang/crystal/pull/16859

This should only be merged if we only want to support 1.17.0 and up as
is not a critical thing we have to fix, so this PR can wait until we
deprecate Crystal <1.17.0
This commit is contained in:
Fijxu 2026-04-27 20:26:34 -04:00
parent fd313e0107
commit 2ac549c40a
No known key found for this signature in database
GPG Key ID: 32C1DDF333EDA6A4

View File

@ -14,7 +14,6 @@ end
class Invidious::LogHandler < Kemal::BaseLogHandler class Invidious::LogHandler < Kemal::BaseLogHandler
def initialize(@io : IO = STDOUT, @level = LogLevel::Debug, use_color : Bool = true) def initialize(@io : IO = STDOUT, @level = LogLevel::Debug, use_color : Bool = true)
Colorize.enabled = use_color Colorize.enabled = use_color
Colorize.on_tty_only!
end end
def call(context : HTTP::Server::Context) def call(context : HTTP::Server::Context)