read-only should work now

This commit is contained in:
2024-01-22 11:51:30 -08:00
parent 87bd655253
commit bfa162e1cf
2 changed files with 4 additions and 4 deletions

View File

@@ -49,18 +49,17 @@
:db/id (:db/id user)
:user/role (name (:user/role user))
:user/name (:user/name user)}
(#{"admin" "read-only"} (name (:user/role user)))
(#{"admin" "read-only"} (name (:user/role user)))
(assoc :gz-clients (->> (:user/clients user)
(map (fn [c]
(select-keys c [:client/code :db/id :client/locations])))
gzip))
(not= "admin" (name (:user/role user)))
(not (#{"read-only" "admin"} (name (:user/role user))))
(assoc :user/clients
(->> (:user/clients user)
(map (fn [c]
(select-keys c [:client/code :db/id :client/locations]))))))]
(when (and user oauth-token)
auth)))

View File

@@ -0,0 +1 @@
(user/start-db)