TBR: playground: Handle CORS before returning 501 Not Implemented.
Change-Id: Ic066a112e01974a2530597f22a4f965bfb1b41ab
diff --git a/client/.gitignore b/client/.gitignore
index 1df0517..2d92022 100644
--- a/client/.gitignore
+++ b/client/.gitignore
@@ -1,6 +1,7 @@
bundles/*/*/bin
bundles/*/*/pkg
public/bundles
+public/version
bundle.*
!browser/components/bundle.js
bundle_*.json
diff --git a/go/src/v.io/x/playground/compilerd/jobqueue/jobqueue.go b/go/src/v.io/x/playground/compilerd/jobqueue/jobqueue.go
index 3b182d5..c87baaf 100644
--- a/go/src/v.io/x/playground/compilerd/jobqueue/jobqueue.go
+++ b/go/src/v.io/x/playground/compilerd/jobqueue/jobqueue.go
@@ -138,7 +138,7 @@
// start starts a given number of workers, then reads from the jobQueue and
// assigns jobs to free workers.
func (d *dispatcherImpl) start(num int) {
- log.Debugf("Dispatcher starting.\n", num)
+ log.Debugf("Dispatcher starting.\n")
// Workers are published on the workerQueue when they are free.
workerQueue := make(chan *worker, num)
diff --git a/go/src/v.io/x/playground/compilerd/main.go b/go/src/v.io/x/playground/compilerd/main.go
index 136f9d9..b2c53f7 100644
--- a/go/src/v.io/x/playground/compilerd/main.go
+++ b/go/src/v.io/x/playground/compilerd/main.go
@@ -245,6 +245,9 @@
}
func handlerNotImplemented(w http.ResponseWriter, r *http.Request) {
+ if !handleCORS(w, r) {
+ return
+ }
+
w.WriteHeader(http.StatusNotImplemented)
- return
}