shared: FilesSverOptions: Rename members

This commit is contained in:
Albert S. 2023-01-08 17:37:28 +01:00
джерело 8298b675aa
коміт ccc4d09b36
3 змінених файлів з 7 додано та 7 видалено

@ -83,8 +83,8 @@ int CommandAdd::handle(QStringList arguments)
FileSaverOptions fileSaverOptions;
fileSaverOptions.keepGoing = keepGoing;
fileSaverOptions.fillPathsOnlyWithContent = fillContent;
fileSaverOptions.pathsOnly = pathsOnly;
fileSaverOptions.fillExistingContentless = fillContent;
fileSaverOptions.metadataOnly = pathsOnly;
fileSaverOptions.verbose = false;
indexer = new Indexer(*this->dbService);

@ -127,10 +127,10 @@ SaveFileResult FileSaver::saveFile(const QFileInfo &fileInfo)
}
}
bool mustFillContent = this->fileSaverOptions.fillPathsOnlyWithContent;
bool mustFillContent = this->fileSaverOptions.fillExistingContentless;
if(!mustFillContent)
{
mustFillContent = !this->fileSaverOptions.pathsOnly;
mustFillContent = !this->fileSaverOptions.metadataOnly;
if(mustFillContent)
{
auto filetype = this->dbService->queryFileType(fileInfo.absolutePath());
@ -176,7 +176,7 @@ SaveFileResult FileSaver::saveFile(const QFileInfo &fileInfo)
}
}
}
SaveFileResult result = this->dbService->saveFile(fileInfo, pageData, this->fileSaverOptions.pathsOnly);
SaveFileResult result = this->dbService->saveFile(fileInfo, pageData, this->fileSaverOptions.metadataOnly);
if(result == OK && processorReturnCode == OK_WASEMPTY)
{
return OK_WASEMPTY;

@ -6,9 +6,9 @@ class FileSaverOptions
public:
bool verbose = false;
bool keepGoing = false;
bool pathsOnly = false;
bool metadataOnly = false;
/* Whether those previously explicitly without content should be filled */
bool fillPathsOnlyWithContent = false;
bool fillExistingContentless = false;
};
#endif // FILESAVEROPTIONS_H