Add simple error management