Avoid redundant internal calls to services/users/user
following5 opened this issue · 2 comments
following5 commented
All the editing, delting and "capabilites" methods need to verify the user. Currently this needs redundant calls to a services/users
method to map between UUID and internal user id.
Evaluate if we can either
- add the internal user ID to the
owner
/user
return value of internally requested caches and logs, or - add the user UUID to request tokens.
following5 commented
Typical example: commit 714f090. Need to pass the $request and UUID and then redundantly fetch the (owner's) user data, to get the internal ID.
I think we should automatically add an internal_id
field to the geocaches owner
and log entry user
fields for all internal method calls.
following5 commented
A good solution is to add owner_fields
and log_user_fields
options to services/caches/geocache(s), and user_fields
option to services/logs/entry(s). This allows to query the internal IDs, if needed.