Some improvements to folder shortcut creation script

I've changed some code to improve folder shortcut creation script.