Move user whitelist to config

This commit is contained in:
Teemu Patja 2017-11-09 17:13:07 +02:00
parent 48f2d024fe
commit e70a72a978
No known key found for this signature in database
GPG Key ID: F5B7035E6580FD4C
1 changed files with 3 additions and 23 deletions

View File

@ -13,7 +13,6 @@
[commiteth.eth.core :as eth]
[commiteth.github.core :as github]
[clojure.tools.logging :as log]
[commiteth.eth.core :as eth]
[commiteth.config :refer [env]]
[commiteth.util.util :refer [usd-decimal->str
eth-decimal->str]]
@ -186,28 +185,9 @@
(dissoc :email)
(assoc :status-team-member? status-member?))}))
;; NOTE: This assumes username can be trusted and not tampered with
(def user-whitelisted?
#{"oskarth"
"tpatja"
"carlbennetts"
"jarradh"
"anna02test"
"anna03test"
"anna04test"
"anna05test"
"anna06test"
"anna07test"
"anna08test"
"anna09test"
"pablanopete"
"andytudhope"
"ara4n"
"commitethtest"
"noman-land"
"cancuncoconut"
"Chu127001"
"izqui"})
(defn user-whitelisted? [user]
(let [whitelist (env :user-whitelist #{})]
(whitelist user)))
(defapi service-routes
(when (:dev env)