Revert "TD-502: Enable usage of user_id and party_id from token (#26)" (#27)

This reverts commit 2de9367561.
This commit is contained in:
Aleksey Kashapov 2023-02-27 10:46:08 +03:00 committed by GitHub
parent 2de9367561
commit 031d6effbb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 5 deletions

View File

@ -111,11 +111,15 @@ get_subject_id(Context) ->
-spec get_user_id(processing_context()) -> binary().
get_user_id(Context) ->
capi_auth:get_user_id(get_auth_context(Context)).
%% TODO Replace when user ids finally stop being equal to party ids
%% capi_auth:get_user_id(get_auth_context(Context)).
get_subject_id(Context).
-spec get_party_id(processing_context()) -> binary().
get_party_id(Context) ->
capi_auth:get_party_id(get_auth_context(Context)).
%% TODO Replace when user ids finally stop being equal to party ids
%% capi_auth:get_party_id(get_auth_context(Context)).
get_subject_id(Context).
%% Utils

View File

@ -173,15 +173,13 @@ combine_metadata(#{} = FullMetadata) ->
user_session_metadata() ->
genlib_map:compact(#{
?TK_META_PARTY_ID => ?PARTY_ID,
?TK_META_USER_ID => ?USER_ID,
?TK_META_USER_EMAIL => ?USER_EMAIL
}).
api_key_metadata() ->
genlib_map:compact(#{
?TK_META_PARTY_ID => ?PARTY_ID,
?TK_META_USER_ID => ?USER_ID
?TK_META_PARTY_ID => ?PARTY_ID
}).
consumer_metadata(Consumer) ->