mirror of
https://github.com/penpot/penpot.git
synced 2026-09-18 18:06:14 +00:00
Revert ✨ Add can use trial prop in nitrate profile (#8954)
This commit is contained in:
parent
78a16d99a9
commit
707cc53ca4
@ -33,27 +33,15 @@
|
|||||||
|
|
||||||
;; ---- API: authenticate
|
;; ---- API: authenticate
|
||||||
|
|
||||||
(def ^:private schema:nitrate-profile
|
|
||||||
[:map {:title "NitrateProfile"}
|
|
||||||
[:id ::sm/uuid]
|
|
||||||
[:name {:optional true} :string]
|
|
||||||
[:email {:optional true} :string]
|
|
||||||
[:photo-url {:optional true} :string]
|
|
||||||
[:theme {:optional true} :string]
|
|
||||||
[:can-use-trial ::sm/boolean]])
|
|
||||||
|
|
||||||
(sv/defmethod ::authenticate
|
(sv/defmethod ::authenticate
|
||||||
"Authenticate the current user"
|
"Authenticate the current user"
|
||||||
{::doc/added "2.14"
|
{::doc/added "2.14"
|
||||||
::sm/params [:map]
|
::sm/params [:map]
|
||||||
::sm/result schema:nitrate-profile}
|
::sm/result schema:profile}
|
||||||
[cfg {:keys [::rpc/profile-id] :as params}]
|
[cfg {:keys [::rpc/profile-id] :as params}]
|
||||||
(let [profile (profile/get-profile cfg profile-id)
|
(let [profile (profile/get-profile cfg profile-id)]
|
||||||
nitrate-subscription (:subscription profile)
|
|
||||||
can-use-nitrate-trial (nil? nitrate-subscription)]
|
|
||||||
(-> (profile-to-map profile)
|
(-> (profile-to-map profile)
|
||||||
(assoc :can-use-nitrate-trial can-use-nitrate-trial
|
(assoc :theme (:theme profile)))))
|
||||||
:theme (:theme profile)))))
|
|
||||||
|
|
||||||
;; ---- API: get-teams
|
;; ---- API: get-teams
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user