some script tweaks