unexpected end fix