Correctly detect project references.