bug fix

error fix for the scripts