Skip to content

Commit

Permalink
исправлено создание папки, если она не существует
Browse files Browse the repository at this point in the history
fix #6
  • Loading branch information
abramcumner committed Jun 13, 2019
1 parent 47a0186 commit 6edbb13
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion sources/utils/converter/batch_helper.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ batch_helper::~batch_helper() {}
bool batch_helper::prepare_target_name(const cl_parser& cl)
{
if (cl.get_string("-dir", m_output_folder)) {
if (!xr_file_system::folder_exist(m_output_folder)) {
if (!xr_file_system::folder_exist(m_output_folder) && !xr_file_system::instance().create_folder(m_output_folder)) {
msg("output folder does not exist");
return false;
}
Expand Down
3 changes: 0 additions & 3 deletions sources/utils/converter/object_tools.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,6 @@ std::function<bool(const std::string&)> create_filter(const std::string& motion_

void object_tools::save_skl(xray_re::xr_object& object, const char* source, const cl_parser& cl) const
{
if (m_output_file.empty() && !m_output_folder.empty())
xr_file_system::instance().create_path(m_output_folder);

std::string motion_name;
cl.get_string("-skl", motion_name);

Expand Down

0 comments on commit 6edbb13

Please sign in to comment.