mirror of
https://github.com/muety/wakapi.git
synced 2023-08-10 21:12:56 +03:00
Fix summary merging.
Rename some methods. Use pointers for structs and none for primitives.
This commit is contained in:
@ -76,7 +76,7 @@ func (h *SummaryHandler) Get(w http.ResponseWriter, r *http.Request) {
|
||||
cacheKey := getHash([]time.Time{from, to}, user)
|
||||
if cachedSummary, ok := h.Cache.Get(cacheKey); !ok {
|
||||
// Cache Miss
|
||||
summary, err = h.SummarySrvc.CreateSummary(from, to, user) // 'to' is always constant
|
||||
summary, err = h.SummarySrvc.Construct(from, to, user) // 'to' is always constant
|
||||
if err != nil {
|
||||
w.WriteHeader(http.StatusInternalServerError)
|
||||
return
|
||||
|
Reference in New Issue
Block a user