mirror of
				https://gitea.invidious.io/iv-org/shard-kemal.git
				synced 2024-08-15 00:53:36 +00:00 
			
		
		
		
	Remove unused stuff
This commit is contained in:
		
							parent
							
								
									536108c71b
								
							
						
					
					
						commit
						6fbad555d0
					
				
					 8 changed files with 6 additions and 4 deletions
				
			
		|  | @ -60,9 +60,11 @@ module Kemal | ||||||
|     end |     end | ||||||
| 
 | 
 | ||||||
|     config.server ||= HTTP::Server.new(config.host_binding, config.port, config.handlers) |     config.server ||= HTTP::Server.new(config.host_binding, config.port, config.handlers) | ||||||
|  | 
 | ||||||
|     {% if !flag?(:without_openssl) %} |     {% if !flag?(:without_openssl) %} | ||||||
|       config.server.not_nil!.tls = config.ssl |       config.server.not_nil!.tls = config.ssl | ||||||
|     {% end %} |     {% end %} | ||||||
|  | 
 | ||||||
|     config.running = true |     config.running = true | ||||||
| 
 | 
 | ||||||
|     yield config |     yield config | ||||||
|  |  | ||||||
|  | @ -18,7 +18,6 @@ module Kemal | ||||||
|       @ssl : OpenSSL::SSL::Context::Server? |       @ssl : OpenSSL::SSL::Context::Server? | ||||||
|     {% end %} |     {% end %} | ||||||
| 
 | 
 | ||||||
|     getter custom_handler_position |  | ||||||
|     property host_binding, ssl, port, env, public_folder, logging, running |     property host_binding, ssl, port, env, public_folder, logging, running | ||||||
|     property always_rescue, server : HTTP::Server?, extra_options, shutdown_message |     property always_rescue, server : HTTP::Server?, extra_options, shutdown_message | ||||||
|     property serve_static : (Bool | Hash(String, Bool)) |     property serve_static : (Bool | Hash(String, Bool)) | ||||||
|  |  | ||||||
|  | @ -13,7 +13,6 @@ class HTTP::Request | ||||||
| 
 | 
 | ||||||
|   # Checks if method contained in _method param is valid one |   # Checks if method contained in _method param is valid one | ||||||
|   def self.override_method_valid?(override_method : String) |   def self.override_method_valid?(override_method : String) | ||||||
|     return false unless override_method.is_a?(String) |  | ||||||
|     override_method = override_method.upcase |     override_method = override_method.upcase | ||||||
|     override_method == "PUT" || override_method == "PATCH" || override_method == "DELETE" |     override_method == "PUT" || override_method == "PATCH" || override_method == "DELETE" | ||||||
|   end |   end | ||||||
|  |  | ||||||
|  | @ -5,6 +5,7 @@ module Kemal | ||||||
|   # These methods are useful for the conditional execution of custom handlers . |   # These methods are useful for the conditional execution of custom handlers . | ||||||
|   class Handler |   class Handler | ||||||
|     include HTTP::Handler |     include HTTP::Handler | ||||||
|  | 
 | ||||||
|     @@only_routes_tree = Radix::Tree(String).new |     @@only_routes_tree = Radix::Tree(String).new | ||||||
|     @@exclude_routes_tree = Radix::Tree(String).new |     @@exclude_routes_tree = Radix::Tree(String).new | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -3,6 +3,7 @@ module Kemal | ||||||
|   # *Content-Type* or *X-Powered-By* headers. |   # *Content-Type* or *X-Powered-By* headers. | ||||||
|   class InitHandler |   class InitHandler | ||||||
|     include HTTP::Handler |     include HTTP::Handler | ||||||
|  | 
 | ||||||
|     INSTANCE = new |     INSTANCE = new | ||||||
| 
 | 
 | ||||||
|     def call(context : HTTP::Server::Context) |     def call(context : HTTP::Server::Context) | ||||||
|  |  | ||||||
|  | @ -1,8 +1,6 @@ | ||||||
| module Kemal | module Kemal | ||||||
|   # Uses `STDOUT` by default and handles the logging of request/response process time. |   # Uses `STDOUT` by default and handles the logging of request/response process time. | ||||||
|   class LogHandler < Kemal::BaseLogHandler |   class LogHandler < Kemal::BaseLogHandler | ||||||
|     @io : IO |  | ||||||
| 
 |  | ||||||
|     def initialize(@io : IO = STDOUT) |     def initialize(@io : IO = STDOUT) | ||||||
|     end |     end | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -3,6 +3,7 @@ require "radix" | ||||||
| module Kemal | module Kemal | ||||||
|   class RouteHandler |   class RouteHandler | ||||||
|     include HTTP::Handler |     include HTTP::Handler | ||||||
|  | 
 | ||||||
|     INSTANCE = new |     INSTANCE = new | ||||||
|     property routes |     property routes | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -1,6 +1,7 @@ | ||||||
| module Kemal | module Kemal | ||||||
|   class WebSocketHandler |   class WebSocketHandler | ||||||
|     include HTTP::Handler |     include HTTP::Handler | ||||||
|  | 
 | ||||||
|     INSTANCE = new |     INSTANCE = new | ||||||
|     property routes |     property routes | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue