Fix right and error management