Skip to content

Commit baf55bd

Browse files
committed
chore: Rename local var (app_dir -> temp_dir) to avoid any ambiguity with o.app_dir
1 parent 9972239 commit baf55bd

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/main/learnocaml_main.ml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -397,16 +397,16 @@ let main o =
397397
if not (List.mem Serve o.commands) then
398398
Lwt.return o.app_dir
399399
else if o.server.Server.replace then
400-
let app_dir = temp_app_dir o in
401-
(if Sys.file_exists app_dir then
400+
let temp_dir = temp_app_dir o in
401+
(if Sys.file_exists temp_dir then
402402
(Printf.eprintf "Warning: temporary directory %s already exists\n%!"
403-
app_dir;
403+
temp_dir;
404404
Lwt.return_unit)
405405
else if Sys.file_exists o.app_dir then
406-
Lwt_utils.copy_tree o.app_dir app_dir
406+
Lwt_utils.copy_tree o.app_dir temp_dir
407407
else
408408
Lwt.return_unit)
409-
>>= fun () -> Lwt.return app_dir
409+
>>= fun () -> Lwt.return temp_dir
410410
else if Learnocaml_server.check_running () <> None then
411411
(Printf.eprintf
412412
"Error: another server is already running on port %d \

0 commit comments

Comments
 (0)