Fixing validation errors