attributes error fix