available_contexts returns [] instead of nil on error

Fix #212