(refactor) Deduplicate operatingsystem fact resolution