Cleaned up JS