2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Write uint8 tags to Database and count stats.

Also pass rvalues to Database where copies are required anyway.
This commit is contained in:
John Preston
2018-08-28 23:49:16 +03:00
parent 2e7f4c2f21
commit e2f08d4161
10 changed files with 306 additions and 179 deletions

View File

@@ -1022,7 +1022,9 @@ void RemoteImage::setImageBytes(
const auto location = this->location();
if (!location.isNull() && !bytes.isEmpty()) {
Auth().data().cache().putIfEmpty(Data::StorageCacheKey(location), bytes);
Auth().data().cache().putIfEmpty(
Data::StorageCacheKey(location),
base::duplicate(bytes));
}
}