edit per SVS

Move Lines 40-43 to be executed before setfacl and chmod commands.