equal
deleted
inserted
replaced
99 for (auto& finder : attributeFinders) finder.second->startFile(file); |
99 for (auto& finder : attributeFinders) finder.second->startFile(file); |
100 |
100 |
101 for (RequestedField field : configuration.fields) { |
101 for (RequestedField field : configuration.fields) { |
102 AttributeFinder* finder = attributeFinders[field.group]; // should not be nullptr, because already checked while writing the relation metadata |
102 AttributeFinder* finder = attributeFinders[field.group]; // should not be nullptr, because already checked while writing the relation metadata |
103 |
103 |
|
104 // TODO: links to non-existent files are currently treated as non-existent files → we still can return the type and symlink_target values |
104 if (exists || (field.group == RequestedField::GROUP_FILE && field.name == FileAttributeFinder::FIELD_PATH_ORIGINAL)) { |
105 if (exists || (field.group == RequestedField::GROUP_FILE && field.name == FileAttributeFinder::FIELD_PATH_ORIGINAL)) { |
105 finder->writeField(writer.get(), field); |
106 finder->writeField(writer.get(), field); |
106 } else { |
107 } else { |
107 finder->writeEmptyField(writer.get(), field); |
108 finder->writeEmptyField(writer.get(), field); |
108 } |
109 } |
109 } |
110 } |
110 |
111 |
111 for (auto& finder : attributeFinders) finder.second->endFile(); |
112 for (auto& finder : attributeFinders) finder.second->endFile(); |
112 } |
113 } |
113 } |
114 } |
114 }; |
115 }; |
115 |
116 |