Missing then in an if on line 1366