Remove unused lines in spec and js