Skip to content

Commit

Permalink
Fix TailwindCSS related server rebuild issue
Browse files Browse the repository at this point in the history
Fixes #13316
  • Loading branch information
bep committed Jan 29, 2025
1 parent e08d9af commit 2a663b1
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions hugolib/hugo_sites_build.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import (

"github.com/bep/logg"
"github.com/gohugoio/hugo/bufferpool"
"github.com/gohugoio/hugo/cache/dynacache"
"github.com/gohugoio/hugo/deps"
"github.com/gohugoio/hugo/hugofs"
"github.com/gohugoio/hugo/hugofs/files"
Expand Down Expand Up @@ -1062,6 +1063,18 @@ func (h *HugoSites) processPartialFileEvents(ctx context.Context, l logg.LevelLo

resourceFiles := h.fileEventsContentPaths(addedOrChangedContent)

defer func() {
// See issue 13316.
h.MemCache.DrainEvictedIdentitiesMatching(func(ki dynacache.KeyIdentity) bool {
for _, c := range changes {
if c.IdentifierBase() == ki.Identity.IdentifierBase() {
return true
}
}
return false
})
}()

changed := &WhatChanged{
needsPagesAssembly: needsPagesAssemble,
identitySet: make(identity.Identities),
Expand Down

0 comments on commit 2a663b1

Please sign in to comment.