fix master script