fixed bug upon opening APP