mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 03:15:51 +08:00
Fix of faulty upload to Connect, when upload is set before slicing ends.
This commit is contained in:
parent
eb7f27c83d
commit
a361f78067
@ -280,9 +280,6 @@ std::string get_print_data_from_json(const std::string& json, const std::string&
|
||||
size_t start_of_sub = json.find('{', start_of_keyword);
|
||||
if (start_of_sub == std::string::npos)
|
||||
return {};
|
||||
size_t end_of_sub = json.find('}', start_of_sub);
|
||||
if (end_of_sub == std::string::npos)
|
||||
return {};
|
||||
size_t start_of_filename = json.find("\"filename\"", start_of_sub);
|
||||
if (start_of_filename == std::string::npos)
|
||||
return {};
|
||||
@ -295,6 +292,9 @@ std::string get_print_data_from_json(const std::string& json, const std::string&
|
||||
size_t end_of_filename_data = json.find('\"', start_of_filename_data + 1);
|
||||
if (end_of_filename_data == std::string::npos)
|
||||
return {};
|
||||
size_t end_of_sub = json.find('}', end_of_filename_data);
|
||||
if (end_of_sub == std::string::npos)
|
||||
return {};
|
||||
size_t size = json.size();
|
||||
std::string result = json.substr(start_of_sub, start_of_filename_data - start_of_sub + 1);
|
||||
result += "%1%";
|
||||
|
Loading…
x
Reference in New Issue
Block a user