File tree Expand file tree Collapse file tree 1 file changed +11
-7
lines changed
lib/graphql/fragment_cache Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -30,13 +30,17 @@ def read_multi(fragments)
3030 FragmentCache . cache_store . read_multi ( *cache_keys )
3131 end
3232
33- fragments . map do |fragment |
34- cache_lookup_event (
35- cache_key : fragment . cache_key ,
36- operation_name : fragment . context . query . operation_name ,
37- path : fragment . path ,
38- cache_hit : cache_keys_to_values . key? ( fragment . cache_key ) ,
39- )
33+ begin
34+ fragments . map do |fragment |
35+ cache_lookup_event (
36+ cache_key : fragment . cache_key ,
37+ operation_name : fragment . context . query . operation_name ,
38+ path : fragment . path ,
39+ cache_hit : cache_keys_to_values . key? ( fragment . cache_key ) ,
40+ )
41+ end
42+ rescue
43+ # Allow cache_lookup_event to fail when we do not have the data we need
4044 end
4145
4246 # Fragmenst without values or with renew_cache: true in their context will have nil values like the read method
You can’t perform that action at this time.
0 commit comments