gin-contrib / cache

Gin middleware/handler to enable Cache
https://gin-gonic.github.io/gin
MIT License
378 stars 96 forks source link

Fix redis serialization error #10

Closed NilsJPWerner closed 6 years ago

NilsJPWerner commented 7 years ago

Fixes the redis bug mentioned in this issue from the previous repo: https://github.com/gin-gonic/contrib/issues/29

The responseCache struct has no exported fields and thus cannot be serialized into bytes. This PR makes all the fields exported so that redis caching works.

codecov-io commented 7 years ago

Codecov Report

Merging #10 into master will not change coverage. The diff coverage is 57.14%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #10   +/-   ##
=======================================
  Coverage   71.42%   71.42%           
=======================================
  Files           1        1           
  Lines          77       77           
=======================================
  Hits           55       55           
  Misses         20       20           
  Partials        2        2
Impacted Files Coverage Δ
cache.go 71.42% <57.14%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update d02ffee...fe62f0c. Read the comment docs.