anchor.diff:              #state{replace = undefined} = State) ->
       State;
   replace_hit(#file{size = ContentsSize,
  -                  path = FilePath}, _TimeNativeOld,
  +                  path = FilePath}, TimeNativeOld,
               #state{directory_length = DirectoryLength,
  -                   replace = #lfuda{policy = Policy,
  -                                    age = Age},
  +                   replace = Replace,
                      replace_hit = ReplaceHit} = State) ->
       FileName = lists:nthtail(DirectoryLength, FilePath),
  -    ReplaceHitNew = cloudi_x_trie:update(FileName, fun({_, HitsOld}) ->
  +    State#state{replace_hit = replace_hit_update(FileName, ContentsSize,
  +                                                 TimeNativeOld,
  +                                                 Replace, ReplaceHit)}.
  +
  +replace_hit_update(_, _, _,
  +                   undefined, ReplaceHit) ->
  +    ReplaceHit;
  +replace_hit_update(FileName, ContentsSize, _,
  +                   #lfuda{policy = Policy,
  +                          age = Age}, ReplaceHit) ->
  +    cloudi_x_trie:update(FileName, fun({_, HitsOld}) ->
           Hits = HitsOld + 1,
           PriorityKey = if
               Policy =:= lfuda ->
  
positive.code:         Value
      end, TimeNative, ReplaceHit).
  
  replace_remove(_, undefined, ReplaceHit) ->
      ReplaceHit;
  replace_remove(FileName,
                 #lfuda{age = Age} = Replace, ReplaceHit) ->
      case cloudi_x_trie:take(FileName, ReplaceHit) of
  
negative.code:                                            mtime_i = MTimeI,
                                             access = Access,
                                             toggle = Toggle},
                          ReplaceHit2 = replace_hit_update(FileName,
                                                           ContentsSize,
                                                           TimeNative,
                                                           Replace1,
                                                           ReplaceHit1),
                          {ReplaceHit2, Replace1, FilesSize2,
                           file_refresh(FileName, File1, Files1,
                                        UseHttpGetSuffix, Prefix)};
                      {files_size, ContentsSize} ->
  