toggle function.

I think I may have it.  I applied more partitions(parentheses, braces,
etc.) to the function for opening and closing.