Remove trailing slash from recent dir if needed
Remove trailing slash from recent dir if needed

(cherry picked from commit 709e71ae9c050a5b28b662d885d24acf31853a80)

ex/godot,ex/godot,ex/godot,ex/godot,ex/godot,ex/godot,ex/godot,ex/godot