fixing issue with unauthorized.

This commit is contained in:
Bryce Covert
2018-09-18 07:21:53 -07:00
parent b17d564cdf
commit 52cbddcbde

View File

@@ -47,7 +47,8 @@
(defn can-see-company? [identity company]
(or (= "admin" (:role identity))
((set (:companies identity)) (:id company))))
((set (:companies identity)) (:id company))
((set (:companies identity)) company)))
(defn assert-can-see-company [identity company]
(when-not (can-see-company? identity company)