mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#4429 Implement return status handling for command file interface
This commit is contained in:
@@ -40,7 +40,7 @@ RicfSetExportFolder::RicfSetExportFolder()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RicfSetExportFolder::execute()
|
||||
RicfCommandResponse RicfSetExportFolder::execute()
|
||||
{
|
||||
if (m_createFolder)
|
||||
{
|
||||
@@ -52,11 +52,14 @@ void RicfSetExportFolder::execute()
|
||||
|
||||
if (!dir.exists(m_path))
|
||||
{
|
||||
RiaLogging::error("Could not create folder : " + m_path);
|
||||
QString error = QString("Could not create folder : %1").arg(m_path);
|
||||
RiaLogging::error(error);
|
||||
return RicfCommandResponse(RicfCommandResponse::COMMAND_ERROR, error);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
RicfCommandFileExecutor* executor = RicfCommandFileExecutor::instance();
|
||||
executor->setExportPath(m_type(), m_path);
|
||||
return RicfCommandResponse();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user