···108108 FormatRecipeHTML(p, *recipe, signedIn, thread, *feedback, w)
109109 return
110110 }
111111-111111+ //we didn't go back and update old recipes's with new hash so have to handle that here. Could still backfill
112112+ if normalizedHash, ok := legacyHashToCurrent(recipe.OriginHash, legacyRecipeHashSeed); ok {
113113+ slog.InfoContext(ctx, "normalized legacy origin hash to current hash", "origin_hash", recipe.OriginHash, "hash", normalizedHash)
114114+ recipe.OriginHash = normalizedHash
115115+ //could resave to backfill but don't think we'll ever get them all without looping
116116+ }
112117 p, err := s.ParamsFromCache(ctx, recipe.OriginHash)
113118 if err != nil {
114119 slog.ErrorContext(ctx, "failed to load params for hash", "hash", recipe.OriginHash, "error", err)
···328333func (s *server) handleRecipes(w http.ResponseWriter, r *http.Request) {
329334 ctx := r.Context()
330335 if hashParam := r.URL.Query().Get(queryArgHash); hashParam != "" {
331331- if normalizedHash, ok := normalizeLegacyRecipeHash(hashParam); ok {
336336+ if normalizedHash, ok := legacyHashToCurrent(hashParam, legacyRecipeHashSeed); ok {
332337 slog.InfoContext(ctx, "redirecting legacy hash to canonical hash", "legacy_hash", hashParam, "hash", normalizedHash)
333338 redirectToHash(w, r, normalizedHash, false /*useStart*/)
334339 return