working on toggle function.