cleaned up JS