FileMananger: do not store file reference is persistent file id
GitOrigin-RevId: 6da317bcac575ed4398a8971229250c0948ee097
This commit is contained in:
parent
bbf67ad700
commit
66c604f2d4
@ -393,6 +393,9 @@ class FullRemoteFileLocation {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
void clear_file_reference() {
|
||||
file_reference_ = "";
|
||||
}
|
||||
|
||||
bool delete_file_reference(Slice bad_file_reference) {
|
||||
auto res = FileReferenceView(file_reference_).delete_file_reference(bad_file_reference);
|
||||
|
@ -2435,7 +2435,9 @@ string FileManager::get_persistent_id(const FullGenerateFileLocation &location)
|
||||
return base64url_encode(binary);
|
||||
}
|
||||
string FileManager::get_persistent_id(const FullRemoteFileLocation &location) {
|
||||
auto binary = serialize(location);
|
||||
auto location_copy = location;
|
||||
location_copy.clear_file_reference();
|
||||
auto binary = serialize(location_copy);
|
||||
|
||||
binary = zero_encode(binary);
|
||||
binary.push_back(PERSISTENT_ID_VERSION);
|
||||
|
Loading…
x
Reference in New Issue
Block a user