lib/spoom/sorbet/lsp.rb in spoom-1.2.2 vs lib/spoom/sorbet/lsp.rb in spoom-1.2.3

- old
+ new

@@ -51,11 +51,11 @@ end sig { returns(T.nilable(T::Hash[T.untyped, T.untyped])) } def read raw_string = read_raw - return nil unless raw_string + return unless raw_string json = JSON.parse(raw_string) # Handle error in the LSP protocol raise ResponseError.from_json(json["error"]) if json["error"] @@ -99,10 +99,10 @@ "character" => column, }, }, )) - return nil unless json && json["result"] + return unless json && json["result"] Hover.from_json(json["result"]) end sig { params(uri: String, line: Integer, column: Integer).returns(T::Array[SignatureHelp]) }