0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen # An ontology being imported into is in this context not only a Mapping with
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen # kind 'import' but any kind of mapping. Otherwise the target ontology's view,
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen # alignment, etc. is invalid.
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen ontology_ids = Mapping.where(target_id: self, kind: 'import').
0cb2e8eb55e70f8ebe1e8349bdf49e4cbe5d8834Timo Sirainen l.target.repository == repository && l.target.path == path