add error handling (removes compile warnings)