lib/ruby_lsp/utils.rb in ruby-lsp-0.4.5 vs lib/ruby_lsp/utils.rb in ruby-lsp-0.5.0

- old
+ new

@@ -4,11 +4,11 @@ module RubyLsp # Used to indicate that a request shouldn't return a response VOID = T.let(Object.new.freeze, Object) # This freeze is not redundant since the interpolated string is mutable - WORKSPACE_URI = T.let("file://#{Dir.pwd}".freeze, String) # rubocop:disable Style/RedundantFreeze + WORKSPACE_URI = T.let(URI("file://#{Dir.pwd}".freeze), URI::Generic) # rubocop:disable Style/RedundantFreeze # A notification to be sent to the client class Message extend T::Sig extend T::Helpers @@ -36,29 +36,24 @@ extend T::Sig sig { returns(T.untyped) } attr_reader :response - sig { returns(T::Array[Message]) } - attr_reader :messages - sig { returns(T.nilable(Exception)) } attr_reader :error sig { returns(T.nilable(Float)) } attr_reader :request_time sig do params( response: T.untyped, - messages: T::Array[Message], error: T.nilable(Exception), request_time: T.nilable(Float), ).void end - def initialize(response:, messages:, error: nil, request_time: nil) + def initialize(response:, error: nil, request_time: nil) @response = response - @messages = messages @error = error @request_time = request_time end end