Fix error result crash