anchor.diff:      CanonicalTargetPath :: file_meta:path(),
       LogicalTargetPath :: file_meta:path()) ->
       ok | logical_file_manager:error_reply().
  --check_permissions([{?delete_object, {parent, 2}}, {?add_object, {parent, {path, 3}}}]).
  +-check_permissions([{?delete_object, {parent, 2}}]).
   rename_file(CTX, SourceEntry, CanonicalTargetPath, LogicalTargetPath) ->
       case check_reg_preconditions(CTX, LogicalTargetPath) of
           ok ->
  -            rename_select(CTX, SourceEntry, CanonicalTargetPath, LogicalTargetPath);
  +            rename_select(CTX, SourceEntry, CanonicalTargetPath, LogicalTargetPath, ?REGULAR_FILE_TYPE);
           Error ->
               Error
       end.
  
positive.code: %%--------------------------------------------------------------------
  -spec rename_select(CTX :: fslogic_worker:ctx(), SourceEntry :: fslogic_worker:file(),
      CanonicalTargetPath :: file_meta:path(),
      LogicalTargetPath :: file_meta:path()) ->
      ok | logical_file_manager:error_reply().
  rename_select(CTX, SourceEntry, CanonicalTargetPath, LogicalTargetPath) ->
      {_, TargetParentPath} = fslogic_path:basename_and_parent(CanonicalTargetPath),
      {ok, #document{key = SourceUUID}} = file_meta:get(SourceEntry),
      SourceSpaceId = fslogic_spaces:get_space_id(SourceUUID),
  
negative.code:     TargetPathTokens = filename:split(LogicalTargetPath),
  
      for_each_child_file(SourceEntry,
          fun(#document{key = SourceUuid} = Doc) ->
              SourceGuid = fslogic_uuid:to_file_guid(SourceUuid),
              {ok, OldPath} = fslogic_path:gen_path(Doc, SessId),
              OldTokens = filename:split(OldPath),
              NewTokens = TargetPathTokens ++ lists:sublist(OldTokens, length(SourcePathTokens) + 1, length(OldTokens)),
  