fixed bug when scope did not update