Update script to handle better variables.