Add 4 more allowed characters for file name from file extension in accordance with Telegram server-side limit.
This commit is contained in:
parent
0baf4cb070
commit
c021bdfb98
@ -159,8 +159,8 @@ string clean_filename(CSlice name) {
|
||||
}
|
||||
|
||||
PathView path_view(name);
|
||||
auto filename = clean_filename_part(path_view.file_stem(), 60);
|
||||
auto extension = clean_filename_part(path_view.extension(), 20);
|
||||
auto filename = clean_filename_part(path_view.file_stem(), 64);
|
||||
auto extension = clean_filename_part(path_view.extension(), 16);
|
||||
if (!extension.empty()) {
|
||||
if (filename.empty()) {
|
||||
filename = std::move(extension);
|
||||
|
Loading…
Reference in New Issue
Block a user