Fix iOS background bug