diff --git a/lib/steep/server/master.rb b/lib/steep/server/master.rb index 1231d1266..ef5c92b43 100644 --- a/lib/steep/server/master.rb +++ b/lib/steep/server/master.rb @@ -472,10 +472,9 @@ def process_message_from_client(message) controller.push_changes(path) case type - when 1, 2 + when LSP::Constant::FileChangeType::CREATED, LSP::Constant::FileChangeType::CHANGED content = path.read - when 4 - # Deleted + when LSP::Constant::FileChangeType::DELETED content = "" end diff --git a/sig/shims/language-server_protocol.rbs b/sig/shims/language-server_protocol.rbs index 93e02fd50..41ef5f8dd 100644 --- a/sig/shims/language-server_protocol.rbs +++ b/sig/shims/language-server_protocol.rbs @@ -142,6 +142,14 @@ module LanguageServer end TextDocumentSyncKind: __todo__ + + module FileChangeType + CREATED: 1 + CHANGED: 2 + DELETED: 3 + + type t = 1 | 2 | 3 + end end module Interface