@Override
		public void versionCreated(int version, String comment, long checkinId)
				throws FileNotFoundException {
			synchronized (syncObject) {
				if (currentVersion != (version - 1)) {
					log.error(dbDir + ": unexpected version created (" + version +
						"), expected version " + (currentVersion + 1));
					if (version > currentVersion || version < minVersion) {
						getBufferFile(version).delete();
					}
					return;
				}

				scanFiles(true);

				if (currentVersion == 0) {
					throw new FileNotFoundException("Database files not found");
				}
				if (version != currentVersion) {
					log.error(dbDir + ": Unexpected version found (" + currentVersion +
						"), expected " + version);
				}
				else if (dbFileListener != null) {
					dbFileListener.versionCreated(Database.this, version);
				}
			}
		}
Scan files and update state.
@param repair if true files are repaired if needed.
Ghidra/Framework/DB/src/main/java/db/Database.java