Skip to content

Commit

Permalink
fix refactored cache code not getting the ld_obj when updating the cache
Browse files Browse the repository at this point in the history
  • Loading branch information
syphax-bouazzouni committed May 27, 2024
1 parent fff5453 commit abea6c2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions config/config.test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
$DEBUG_API_CLIENT = false
LinkedData::Client.config do |config|
config.rest_url = 'https://data.bioontology.org'
config.apikey = ENV['UT_APIKEY']
# config.apikey = 'xxxxx-xxxxx-xxxxxxxxxx'
config.apikey = '8b5b7825-538d-40e0-9e9e-5ab9274a9aeb'
config.links_attr = 'links'
config.cache = false
config.cache = true
config.debug_client = false
end
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def update_cache(request_key, last_modified)
cache_write(last_modified_key_id(request_key), last_modified)
cache_write(request_key, stored_obj)
end
stored_obj
stored_obj.is_a?(Hash) && stored_obj.key?(:ld_obj) ? stored_obj[:ld_obj] : stored_obj
end

def cache_response(response_env, request_key)
Expand Down

0 comments on commit abea6c2

Please sign in to comment.