Need some flexibility in errorhandling