Cleaned up javascript.
Cleaned up javascript.