update toggle button is now working