package hello;

import java.util.concurrent.atomic.AtomicLong;

import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class GreetingController {

    private static final String template = "Hello, %s!";
    private final AtomicLong counter = new AtomicLong();

    @CrossOrigin(origins = "http://localhost:8080")
    @RequestMapping("/greeting")
    public Greeting greeting(@RequestParam(value="name", defaultValue="World") String name) {
        return new Greeting(counter.incrementAndGet(),
                            String.format(template, name));
    }
}

@@ -61,68 +61,8 @@
 g;%0A%0A
-import org.springframework.web.bind.annotation.CrossOrigin;%0A
 impo
@@ -415,60 +415,8 @@
 );%0A%0A
-    @CrossOrigin(origins = %22http://localhost:8080%22)%0A
     

Fix doubled CORS