[UPDATE] (global) Cleaned up javascript