Skip to content

Commit

Permalink
Properly construct File_keys when handling live errors requests
Browse files Browse the repository at this point in the history
Summary: This is the same as the change made in D27577168 (a7e78a7), but at a different callsite

Reviewed By: mroch

Differential Revision: D27596742

fbshipit-source-id: 01c794904f41f27c8a5d43a784dae2bdbb6bc1bf
  • Loading branch information
nmote authored and facebook-github-bot committed Apr 7, 2021
1 parent 0ef1e85 commit ad6424b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/server/command_handler/commandHandler.ml
Original file line number Diff line number Diff line change
Expand Up @@ -2159,7 +2159,10 @@ let handle_live_errors_request =
let%lwt (live_errors, live_warnings) =
match check_that_we_care_about_this_file ~options ~env ~file_path ~content with
| Ok () ->
let file_key = File_key.SourceFile file_path in
let file_key =
let file_options = Options.file_options options in
Files.filename_from_string ~options:file_options file_path
in
let%lwt result =
Types_js.typecheck_contents ~options ~env ~profiling content file_key
in
Expand Down

0 comments on commit ad6424b

Please sign in to comment.