JavaScript: Array.pop