This is our current code for when we fully receive a response from discord. We can leverage the T result to call the cache and update. Using reflection we can grab the object ID and then run cache.add(id, result);
Acceptance Criteria
WHEN sending a request to discords API
AND we receive a success status code
THEN we should update our cache with the retrieved object
When we parse requests using
DiscordResponseParser
, this is a good time for us to update our cache as we currently only update on gateway events.This is our current code for when we fully receive a response from discord. We can leverage the
T result
to call the cache and update. Using reflection we can grab the object ID and then runcache.add(id, result);
Acceptance Criteria WHEN sending a request to discords API AND we receive a success status code THEN we should update our cache with the retrieved object