| 383 | } |
| 384 | |
| 385 | int DB::getFileId(const std::string &path) { |
| 386 | auto it = name2file_id.try_emplace(lowerPathIfInsensitive(path)); |
| 387 | if (it.second) { |
| 388 | int id = files.size(); |
| 389 | it.first->second = files.emplace_back().id = id; |
| 390 | } |
| 391 | return it.first->second; |
| 392 | } |
| 393 | |
| 394 | int DB::update(QueryFile::DefUpdate &&u) { |
| 395 | int file_id = getFileId(u.first.path); |
nothing calls this directly
no test coverage detected