Improve handling of private and missing profiles

Fixes #1