Add load().
Improve error handling.